-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTaskfile.yml
44 lines (38 loc) · 1004 Bytes
/
Taskfile.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
version: '3'
tasks:
update:
aliases: [u]
desc: Update flake inputs
cmds:
- nix flake update
rebuild-switch:
aliases: [rb-s]
desc: Rebuild NixOS and switch immediatly
cmds:
- sudo nixos-rebuild switch
- task: commit-after-rebuilt
rebuild-boot:
aliases: [rb-b]
desc: Rebuild NixOS and enable on next reboot
cmds:
- sudo nixos-rebuild boot
- task: commit-after-rebuilt
garbage-collect:
aliases: [gc]
desc: Run nix Garbage collector
cmds:
- sudo nix-collect-garbage -d
- sudo /run/current-system/bin/switch-to-configuration boot
cleanup-branches:
aliases: [cb]
desc: Cleanup old rebuid branches
cmds:
- ./scripts/cleanup.sh {{.CLI_ARGS}}
commit-after-rebuilt:
internal: true
preconditions:
- sh: 'test "$(git rev-parse --abbrev-ref HEAD)" = "master"'
msg: "Not on master branch, skipping commit"
cmds:
- ./scripts/commit-routine.sh
silent: true