mirror of
https://github.com/buckley310/nixos-config.git
synced 2024-11-09 18:47:02 +00:00
convert "channel" from alias to script
This commit is contained in:
parent
e285d3b362
commit
1d9c086a71
1 changed files with 7 additions and 6 deletions
|
@ -44,6 +44,13 @@
|
||||||
if ln.startswith('size '):
|
if ln.startswith('size '):
|
||||||
print(str(int(ln.split(' ')[-1])/(1024*1024*1024))[:5],'GB')
|
print(str(int(ln.split(' ')[-1])/(1024*1024*1024))[:5],'GB')
|
||||||
'')
|
'')
|
||||||
|
|
||||||
|
(writeScriptBin "channel" ''
|
||||||
|
#!/bin/sh
|
||||||
|
echo "$(curl --silent -L https://channels.nixos.org/nixos-20.09/git-revision)" nixos-20.09
|
||||||
|
echo "$(cat /nix/var/nix/profiles/per-user/root/channels/nixos/.git-revision)" nixos local
|
||||||
|
echo "$(curl --silent -L https://channels.nixos.org/nixos-unstable/git-revision)" nixos-unstable
|
||||||
|
'')
|
||||||
];
|
];
|
||||||
|
|
||||||
virtualisation.podman.enable = true;
|
virtualisation.podman.enable = true;
|
||||||
|
@ -57,12 +64,6 @@
|
||||||
alias p=python3
|
alias p=python3
|
||||||
alias buildsys='nix build -f "<nixpkgs/nixos>" --no-link system'
|
alias buildsys='nix build -f "<nixpkgs/nixos>" --no-link system'
|
||||||
|
|
||||||
alias channel='
|
|
||||||
echo "$(curl --silent -L https://channels.nixos.org/nixos-20.09/git-revision)" nixos-20.09;\
|
|
||||||
echo "$(cat /nix/var/nix/profiles/per-user/root/channels/nixos/.git-revision)" local nixos;\
|
|
||||||
echo "$(curl --silent -L https://channels.nixos.org/nixos-unstable/git-revision) nixos-unstable"
|
|
||||||
'
|
|
||||||
|
|
||||||
function _update_ps1() {
|
function _update_ps1() {
|
||||||
PS1="\n$(${pkgs.callPackage ../pkgs/powerline-go-updated { }}/bin/powerline-go \
|
PS1="\n$(${pkgs.callPackage ../pkgs/powerline-go-updated { }}/bin/powerline-go \
|
||||||
-mode=flat \
|
-mode=flat \
|
||||||
|
|
Loading…
Reference in a new issue