summaryrefslogtreecommitdiff
path: root/python-jupyterlab-copy-nometa.patch
diff options
context:
space:
mode:
authorLars-Dominik Braun <ldb@leibniz-psychology.org>2020-09-23 14:22:29 +0200
committerLars-Dominik Braun <lars@6xq.net>2020-09-23 14:29:47 +0200
commit410eb76ed24b6c3779f96befb66a119eef8e83a2 (patch)
treef93b2f69f96b744ba38273c5950b83dead9b417e /python-jupyterlab-copy-nometa.patch
Initial import
Diffstat (limited to 'python-jupyterlab-copy-nometa.patch')
-rw-r--r--python-jupyterlab-copy-nometa.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/python-jupyterlab-copy-nometa.patch b/python-jupyterlab-copy-nometa.patch
new file mode 100644
index 0000000..5e770c0
--- /dev/null
+++ b/python-jupyterlab-copy-nometa.patch
@@ -0,0 +1,33 @@
1diff '--exclude=*.swp' -Naur jupyterlab-1.2.6.orig/jupyterlab/commands.py jupyterlab-1.2.6/jupyterlab/commands.py
2--- jupyterlab-1.2.6.orig/jupyterlab/commands.py 2020-01-24 17:25:16.238353500 +0100
3+++ jupyterlab-1.2.6/jupyterlab/commands.py 2020-01-31 12:36:10.497375982 +0100
4@@ -1100,7 +1100,7 @@
5 'webpack.prod.minimize.config.js',
6 '.yarnrc', 'yarn.js']:
7 target = pjoin(staging, fname)
8- shutil.copy(pjoin(HERE, 'staging', fname), target)
9+ shutil.copyfile(pjoin(HERE, 'staging', fname), target)
10
11 # Ensure a clean templates directory
12 templates = pjoin(staging, 'templates')
13@@ -1108,7 +1108,10 @@
14 _rmtree(templates, self.logger)
15
16 try:
17- shutil.copytree(pjoin(HERE, 'staging', 'templates'), templates)
18+ shutil.copytree(pjoin(HERE, 'staging', 'templates'), templates,
19+ copy_function=shutil.copyfile)
20+ # cannot replace or disable copytree’s call to .copystat
21+ os.chmod (templates, 0o755)
22 except shutil.Error as error:
23 # `copytree` throws an error if copying to + from NFS even though
24 # the copy is successful (see https://bugs.python.org/issue24564
25@@ -1178,7 +1181,7 @@
26 with open(lock_path, 'w', encoding='utf-8') as f:
27 f.write(template)
28 elif not osp.exists(lock_path):
29- shutil.copy(lock_template, lock_path)
30+ shutil.copyfile(lock_template, lock_path)
31
32 def _get_package_template(self, silent=False):
33 """Get the template the for staging package.json file.