Show More
@@ -181,7 +181,7 b' class BaseIPythonApplication(Application):' | |||
|
181 | 181 | sys.path.remove(old) |
|
182 | 182 | sys.path.append(os.path.abspath(new)) |
|
183 | 183 | if not os.path.isdir(new): |
|
184 | os.makedirs(new, mode=0777) | |
|
184 | os.makedirs(new, mode=0o777) | |
|
185 | 185 | readme = os.path.join(new, 'README') |
|
186 | 186 | if not os.path.exists(readme): |
|
187 | 187 | path = os.path.join(get_ipython_package_dir(), u'config', u'profile') |
@@ -75,7 +75,7 b' class ExtensionManager(Configurable):' | |||
|
75 | 75 | |
|
76 | 76 | def _on_ipython_dir_changed(self): |
|
77 | 77 | if not os.path.isdir(self.ipython_extension_dir): |
|
78 | os.makedirs(self.ipython_extension_dir, mode = 0777) | |
|
78 | os.makedirs(self.ipython_extension_dir, mode = 0o777) | |
|
79 | 79 | |
|
80 | 80 | def load_extension(self, module_str): |
|
81 | 81 | """Load an IPython extension by its module name. |
@@ -138,7 +138,7 b' class ExtensionManager(Configurable):' | |||
|
138 | 138 | """ |
|
139 | 139 | # Ensure the extension directory exists |
|
140 | 140 | if not os.path.isdir(self.ipython_extension_dir): |
|
141 | os.makedirs(self.ipython_extension_dir, mode = 0777) | |
|
141 | os.makedirs(self.ipython_extension_dir, mode = 0o777) | |
|
142 | 142 | |
|
143 | 143 | if os.path.isfile(url): |
|
144 | 144 | src_filename = os.path.basename(url) |
@@ -501,7 +501,7 b' class InteractiveShell(SingletonConfigurable):' | |||
|
501 | 501 | |
|
502 | 502 | def _ipython_dir_changed(self, name, new): |
|
503 | 503 | if not os.path.isdir(new): |
|
504 | os.makedirs(new, mode = 0777) | |
|
504 | os.makedirs(new, mode = 0o777) | |
|
505 | 505 | |
|
506 | 506 | def set_autoindent(self,value=None): |
|
507 | 507 | """Set the autoindent flag, checking for readline support. |
@@ -110,10 +110,10 b' class ProfileDir(LoggingConfigurable):' | |||
|
110 | 110 | |
|
111 | 111 | def check_security_dir(self): |
|
112 | 112 | if not os.path.isdir(self.security_dir): |
|
113 | os.mkdir(self.security_dir, 0700) | |
|
113 | os.mkdir(self.security_dir, 0o700) | |
|
114 | 114 | else: |
|
115 | 115 | try: |
|
116 | os.chmod(self.security_dir, 0700) | |
|
116 | os.chmod(self.security_dir, 0o700) | |
|
117 | 117 | except OSError: |
|
118 | 118 | self.log.warn("Could not set security dir permissions to private.") |
|
119 | 119 | |
@@ -122,10 +122,10 b' class ProfileDir(LoggingConfigurable):' | |||
|
122 | 122 | |
|
123 | 123 | def check_pid_dir(self): |
|
124 | 124 | if not os.path.isdir(self.pid_dir): |
|
125 | os.mkdir(self.pid_dir, 0700) | |
|
125 | os.mkdir(self.pid_dir, 0o700) | |
|
126 | 126 | else: |
|
127 | 127 | try: |
|
128 | os.chmod(self.pid_dir, 0700) | |
|
128 | os.chmod(self.pid_dir, 0o700) | |
|
129 | 129 | except OSError: |
|
130 | 130 | self.log.warn("Could not set pid dir permissions to private.") |
|
131 | 131 |
@@ -860,10 +860,10 b' class path(unicode):' | |||
|
860 | 860 | |
|
861 | 861 | # --- Create/delete operations on directories |
|
862 | 862 | |
|
863 | def mkdir(self, mode=0777): | |
|
863 | def mkdir(self, mode=0o777): | |
|
864 | 864 | os.mkdir(self, mode) |
|
865 | 865 | |
|
866 | def makedirs(self, mode=0777): | |
|
866 | def makedirs(self, mode=0o777): | |
|
867 | 867 | os.makedirs(self, mode) |
|
868 | 868 | |
|
869 | 869 | def rmdir(self): |
@@ -879,7 +879,7 b' class path(unicode):' | |||
|
879 | 879 | """ Set the access/modified times of this file to the current time. |
|
880 | 880 | Create the file if it does not exist. |
|
881 | 881 | """ |
|
882 | fd = os.open(self, os.O_WRONLY | os.O_CREAT, 0666) | |
|
882 | fd = os.open(self, os.O_WRONLY | os.O_CREAT, 0o666) | |
|
883 | 883 | os.close(fd) |
|
884 | 884 | os.utime(self, None) |
|
885 | 885 |
General Comments 0
You need to be logged in to leave comments.
Login now