Compare commits
No commits in common. "e66228c10731b4aa070f58b7fb641e121a17eec9" and "403272e426e55cefc1cffc10a9d2958e74f16bd7" have entirely different histories.
e66228c107
...
403272e426
|
@ -7,7 +7,6 @@ usage() {
|
||||||
echo "type src: Simple coding project"
|
echo "type src: Simple coding project"
|
||||||
echo "type doc: Assignment"
|
echo "type doc: Assignment"
|
||||||
echo "type nix-ld: Run unpatched programs with Nix"
|
echo "type nix-ld: Run unpatched programs with Nix"
|
||||||
echo "type datasci: Python data science project"
|
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -16,8 +15,6 @@ copy_nix_files() {
|
||||||
cp ~/Documents/IT/flake-template.nix flake.nix
|
cp ~/Documents/IT/flake-template.nix flake.nix
|
||||||
elif [ "$1" = "nix-ld" ]; then
|
elif [ "$1" = "nix-ld" ]; then
|
||||||
cp ~/Documents/IT/nix-ld.nix shell.nix
|
cp ~/Documents/IT/nix-ld.nix shell.nix
|
||||||
elif [ "$1" = "datasci" ]; then
|
|
||||||
cp ~/Projects/devenv/python-data-science.nix shell.nix
|
|
||||||
fi
|
fi
|
||||||
cp ~/Documents/IT/shell.nix .
|
cp ~/Documents/IT/shell.nix .
|
||||||
}
|
}
|
||||||
|
@ -37,12 +34,6 @@ direnv_integration() {
|
||||||
direnv allow
|
direnv allow
|
||||||
}
|
}
|
||||||
|
|
||||||
create_dir() {
|
|
||||||
if [ ! -d "$1" ]; then
|
|
||||||
mkdir "$1"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
if [ $# != 1 ]; then
|
if [ $# != 1 ]; then
|
||||||
usage
|
usage
|
||||||
fi
|
fi
|
||||||
|
@ -50,37 +41,29 @@ fi
|
||||||
type=$1
|
type=$1
|
||||||
|
|
||||||
if [ "$type" = "git" ]; then
|
if [ "$type" = "git" ]; then
|
||||||
|
mkdir src data
|
||||||
copy_nix_files "flake"
|
copy_nix_files "flake"
|
||||||
create_dir data
|
|
||||||
create_dir src
|
|
||||||
git_initialization
|
git_initialization
|
||||||
direnv_integration "flake"
|
direnv_integration "flake"
|
||||||
elif [ "$type" = "remote-git" ]; then
|
elif [ "$type" = "remote-git" ]; then
|
||||||
touch README.org
|
touch README.org
|
||||||
cp ~/Documents/IT/gpl-3.0.md LICENSE.md
|
cp ~/Documents/IT/gpl-3.0.md LICENSE.md
|
||||||
copy_nix_files "flake"
|
copy_nix_files "flake"
|
||||||
create_dir data
|
mkdir src tests data
|
||||||
create_dir src
|
|
||||||
git_initialization
|
git_initialization
|
||||||
direnv_integration "flake"
|
direnv_integration "flake"
|
||||||
elif [ "$type" = "doc" ]; then
|
elif [ "$type" = "doc" ]; then
|
||||||
create_dir assets
|
mkdir docs docs/assets
|
||||||
touch Report.org
|
touch docs/Summary.org
|
||||||
touch .project
|
touch .project
|
||||||
elif [ "$type" = "src" ]; then
|
elif [ "$type" = "src" ]; then
|
||||||
copy_nix_files "nix"
|
copy_nix_files "nix"
|
||||||
create_dir data
|
mkdir src data
|
||||||
create_dir src
|
|
||||||
touch .project
|
touch .project
|
||||||
direnv_integration "nix"
|
direnv_integration "nix"
|
||||||
elif [ "$type" = "nix-ld" ]; then
|
elif [ "$type" = "nix-ld" ]; then
|
||||||
copy_nix_files "nix-ld"
|
copy_nix_files "nix-ld"
|
||||||
direnv_integration "nix"
|
direnv_integration "nix"
|
||||||
elif [ "$type" = "datasci" ]; then
|
|
||||||
copy_nix_files "nix"
|
|
||||||
create_dir data
|
|
||||||
touch .project
|
|
||||||
direnv_integration "nix"
|
|
||||||
else
|
else
|
||||||
usage
|
usage
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue