Gentoo Archives: gentoo-commits

From: Brian Dolbec <dolsen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/catalyst:pending commit in: catalyst/
Date: Tue, 01 Sep 2015 05:59:20
Message-Id: 1441082455.8035e2073b3bb7ca3125627a9671b63239f0537f.dolsen@gentoo
1 commit: 8035e2073b3bb7ca3125627a9671b63239f0537f
2 Author: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
3 AuthorDate: Tue Sep 1 04:39:38 2015 +0000
4 Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
5 CommitDate: Tue Sep 1 04:40:55 2015 +0000
6 URL: https://gitweb.gentoo.org/proj/catalyst.git/commit/?id=8035e207
7
8 fileops.py: Fix a bug where the mode was not being passed
9
10 Change the default mode to 0o755
11
12 catalyst/fileops.py | 6 +++---
13 1 file changed, 3 insertions(+), 3 deletions(-)
14
15 diff --git a/catalyst/fileops.py b/catalyst/fileops.py
16 index fd98db2..129d967 100644
17 --- a/catalyst/fileops.py
18 +++ b/catalyst/fileops.py
19 @@ -21,7 +21,7 @@ from snakeoil.osutils import (ensure_dirs as snakeoil_ensure_dirs,
20 from catalyst.support import CatalystError
21
22
23 -def ensure_dirs(path, gid=-1, uid=-1, mode=0777, minimal=True,
24 +def ensure_dirs(path, gid=-1, uid=-1, mode=0o755, minimal=True,
25 failback=None, fatal=False):
26 '''Wrapper to snakeoil.osutil's ensure_dirs()
27 This additionally allows for failures to run
28 @@ -40,7 +40,7 @@ def ensure_dirs(path, gid=-1, uid=-1, mode=0777, minimal=True,
29 :return: True if the directory could be created/ensured to have those
30 permissions, False if not.
31 '''
32 - succeeded = snakeoil_ensure_dirs(path, gid=-1, uid=-1, mode=0777, minimal=True)
33 + succeeded = snakeoil_ensure_dirs(path, gid=-1, uid=-1, mode=mode, minimal=True)
34 if not succeeded:
35 if failback:
36 failback()
37 @@ -50,7 +50,7 @@ def ensure_dirs(path, gid=-1, uid=-1, mode=0777, minimal=True,
38 return succeeded
39
40
41 -def clear_dir(target, mode=0755, chg_flags=False, remove=False):
42 +def clear_dir(target, mode=0o755, chg_flags=False, remove=False):
43 '''Universal directory clearing function
44
45 @target: string, path to be cleared or removed