Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/swoehrl-mw/nix-kubectl-gs
Basic nix flake to install the kubectl-gs plugin
https://github.com/swoehrl-mw/nix-kubectl-gs
devbox kubectl-gs nix-flake
Last synced: about 2 months ago
JSON representation
Basic nix flake to install the kubectl-gs plugin
- Host: GitHub
- URL: https://github.com/swoehrl-mw/nix-kubectl-gs
- Owner: swoehrl-mw
- License: mit
- Created: 2024-06-22T12:29:50.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-11-28T14:01:36.000Z (about 2 months ago)
- Last Synced: 2024-11-28T15:19:38.083Z (about 2 months ago)
- Topics: devbox, kubectl-gs, nix-flake
- Language: Nix
- Homepage:
- Size: 18.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Nix Flake for kubectl-gs
This repository contains a very basic [Nix Flake](https://nixos.wiki/wiki/Flakes) providing the [Giantswarm Kubectl plugin](https://github.com/giantswarm/kubectl-gs) as a package. It is intended to be added to dev shells.
## Usage
To reference this flake use the following format: `github:swoehrl-mw/nix-kubectl-gs/v`. If you just want the latest version and don't care about version pinning, remove the `/v` part.
Example: `github:swoehrl-mw/nix-kubectl-gs/v4.6.0`
To use the package with [devbox](https://www.jetify.com/devbox/docs/), simply add the reference to your `devbox.json` `packages`:
```json
{
"packages": [
"kubectl@latest",
"github:swoehrl-mw/nix-kubectl-gs/v4.6.0"
]
}
```To add the package to a classic [nix-shell](https://nix.dev/tutorials/first-steps/declarative-shell), use the following snippet in your `shell.nix`:
```nix
pkgs.mkShellNoCC {
packages = [
pkgs.kubectl
(builtins.getFlake "github:swoehrl-mw/nix-kubectl-gs/v4.6.0").packages.${builtins.currentSystem}.kubectl-gs
];
}
```## Development
Steps to update the Flake to a new version:
1. Change the version in `calc_hashes.sh` and run the script
2. Edit `flake.nix`:
1. Paste the output of the script into the `source_hashes` block
2. Change the `pkg_version`
3. Commit and push the changes
4. Tag the commit with the new version