aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-07-07 22:27:41 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-07-07 22:27:41 +0200
commit1b2b886d4ecae252397dbab48b417d44a1bcd82d (patch)
tree872056500855aebcef8ced7f63befa69f1042b9e
parentTrying to sort (diff)
downloadjoe-scripts-1b2b886d4ecae252397dbab48b417d44a1bcd82d.tar.gz
joe-scripts-1b2b886d4ecae252397dbab48b417d44a1bcd82d.tar.bz2
joe-scripts-1b2b886d4ecae252397dbab48b417d44a1bcd82d.tar.xz
joe-scripts-1b2b886d4ecae252397dbab48b417d44a1bcd82d.tar.zst
joe-scripts-1b2b886d4ecae252397dbab48b417d44a1bcd82d.zip
File owner fixes
-rwxr-xr-xsrc/gitjoe-chdesc.pl4
-rwxr-xr-xsrc/gitjoe-chowner.pl4
2 files changed, 8 insertions, 0 deletions
diff --git a/src/gitjoe-chdesc.pl b/src/gitjoe-chdesc.pl
index 6784f97..9a9a9e5 100755
--- a/src/gitjoe-chdesc.pl
+++ b/src/gitjoe-chdesc.pl
@@ -24,6 +24,10 @@ sub main {
open(my $desc_fh, '>:encoding(UTF-8)', $home_dir . $repo . 'description');
print $desc_fh $desc;
close($desc_fh);
+ system(
+ '/usr/local/bin/dash',
+ '-c',
+ '/usr/sbin/chown -v ' . $usr . ':' . $usr . ' ' . $home_dir . $repo . 'description'
exit;
}
diff --git a/src/gitjoe-chowner.pl b/src/gitjoe-chowner.pl
index 6d2a5a2..436959e 100755
--- a/src/gitjoe-chowner.pl
+++ b/src/gitjoe-chowner.pl
@@ -24,6 +24,10 @@ sub main {
open(my $owner_fh, '>:encoding(utf-8)', $home_dir . $repo . 'owner');
print $owner_fh $owner;
close($owner_fh);
+ system(
+ '/usr/local/bin/dash',
+ '-c',
+ '/usr/sbin/chown -v ' . $usr . ':' . $usr . ' ' . $home_dir . $repo . 'owner'
exit;
}