core-system-scripts

Scripts submodule for the core-system repository
git clone https://ccx.te2000.cz/git/core-system-scripts
Log | Files | Refs

link-skel (307B)


      1 #!/bin/zsh
      2 main() {
      3 	local f l
      4 	(umask 077 && mkdir -p $HOME/.{config,cache,local/{share/zsh,state}}) || exit $?
      5 	for f in scripts/skel/**/*(.D); do
      6 		l=$HOME/${f#scripts/skel/}
      7 		[[ -e $l ]] && continue
      8 		mkdir -p $l:h || exit $?
      9 		s6-ln -sfn /current/$f $l || exit $?
     10 	done
     11 }
     12 typeset -f -t main
     13 main "$@"