dot

packages and services management
Log | Files | Refs | README

commit 5cc4cb6df4a0953b99e138dc2a8591fef078e8d7
parent 74af3b9e02ec52fecdb1e641ef20f533ca8c2859
Author: Josuah Demangeon <mail@josuah.net>
Date:   Tue, 30 Jan 2018 14:18:56 +0100

Use ${ETC} as a configuration basis, optionnaly set to /etc

This is to help to adapt the configurations and make them less intrusive
on a system where existing configuration takes effect.

Diffstat:
Mdaemon/tincd | 6++++--
Mdot/profile | 4++--
2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/daemon/tincd b/daemon/tincd @@ -2,8 +2,10 @@ netw="${1:-josuah.net}" -[ -r "${ETC}/config/tinc/${netw}/hosts/$(uname -n)" ] || -tinc -n "${netw}" init "$(uname -n)" +if ! [ -r "${ETC}/tinc/${netw}/hosts/$(uname -n)" ] +then + tinc -n "${netw}" init "$(uname -n)" +fi exec tincd \ -n "${netw}" \ diff --git a/dot/profile b/dot/profile @@ -13,8 +13,8 @@ export PAGER='less' export MANPAGER='less' export VAR="${HOME}/.cache" -export LOG="${VAR}/log" -export ETC="${HOME}/etc" +export LOG="${HOME}/.cache/log" +export ETC="${HOME}/.config" export PLAN9="${HOME}/.local/src/plan9" export PATH="${HOME}/etc/bin:${HOME}/.local/bin:${PATH}:${PLAN9}/bin"