explicit chmod

Tue, 13 Jun 2017 11:01:17 -0400

author
Meredith Howard <mhoward@roomag.org>
date
Tue, 13 Jun 2017 11:01:17 -0400
changeset 608
177dfb2889ab
parent 607
042360ae89bb
child 609
46f19b7955d8

explicit chmod

.profile.common file | annotate | diff | comparison | revisions
.ssh/Makefile file | annotate | diff | comparison | revisions
--- a/.profile.common
+++ b/.profile.common
@@ -2,8 +2,10 @@
 
 umask 027
 
-make -s -C ~/.ssh ||
-  cat ~/.ssh/config.d/* > ~/.ssh/config
+make -s -C ~/.ssh || {
+  cat ~/.ssh/config.d/* > ~/.ssh/config &&
+  chmod 600 $_
+}
 
 export EDITOR=vim
 export SUDO_EDITOR=$HOME/bin/privim
--- a/.ssh/Makefile
+++ b/.ssh/Makefile
@@ -2,7 +2,7 @@
 # config.d/10-base to config and add an Include config.d/*
 
 config: config.d/*
-	umask 277 && cat config.d/* > $@
+	cat config.d/* > $@ && chmod 600 $@
 
 clean:
 	rm -f config

mercurial