summary refs log tree commit diff
path: root/link.zsh
blob: e9fa64ca885e379f1b8a2e8c1eb82dab4ea0f8fc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env zsh
set -o errexit -o nounset -o pipefail

if [[ $# -eq 1 ]]; then
    linkPath="$1"
    filePath="$PWD/home/${linkPath#$HOME/}"
    [[ ! -f "$filePath" ]]
    mkdir -p "$(dirname "$filePath")"
    mv "$linkPath" "$filePath"
fi

find home -type f | while read -r findPath; do
    filePath="$PWD/$findPath"
    linkPath="$HOME/${findPath#home/}"
    mkdir -p "$(dirname "$linkPath")"
    [[ ( -f "$linkPath" && -L "$linkPath" ) || ! -f "$linkPath" ]]
    ln -s -f "$filePath" "$linkPath"
done
/td>Move global variables + callback functions into shared.cLars Hjemli 2006-12-11Move functions for generic object output into ui-view.cLars Hjemli 2006-12-11Move log-functions into ui-log.cLars Hjemli 2006-12-11Move repo summary functions into ui-summary.cLars Hjemli 2006-12-11Move functions for repolist output into ui-repolist.cLars Hjemli 2006-12-11Move common output-functions into ui-shared.cLars Hjemli 2006-12-11Rename config.c to parsing.c + move cgit_parse_query from cgit.c to parsing.cLars Hjemli 2006-12-11Avoid infinite loops in caching layerLars Hjemli 2006-12-11Let 'make install' clear all cachefilesLars Hjemli 2006-12-11Fix cache algorithm loopholeLars Hjemli 2006-12-10Add version identifier in generated filesLars Hjemli 2006-12-10Add license file and copyright noticesLars Hjemli 2006-12-10Add caching infrastructureLars Hjemli