For cross-platform build take the linux version of printenv.py
authorDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Thu, 29 Sep 2016 14:41:28 +0000 (16:41 +0200)
committerDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Thu, 29 Sep 2016 14:41:28 +0000 (16:41 +0200)
bin/linux/printenv.py [new file with mode: 0644]
build/groovy/org/jetbrains/intellij/build/impl/CrossPlatformDistributionBuilder.groovy

diff --git a/bin/linux/printenv.py b/bin/linux/printenv.py
new file mode 100644 (file)
index 0000000..a60959c
--- /dev/null
@@ -0,0 +1,18 @@
+#!/usr/bin/env python
+
+# Dumps environment variables into specified file.
+# Format: zero-separated "name=value" pairs in platform encoding.
+
+import os
+import sys
+
+if len(sys.argv) != 2:
+    raise Exception('Exactly one argument expected')
+
+f = open(sys.argv[1], 'wb')
+try:
+    for key, value in os.environ.items():
+        s = '%s=%s\0' % (key, value)
+        f.write(s.encode('utf-8'))
+finally:
+    f.close()
index 6d2cbd5861cb13781dcace41314ddcc429b336d5..88a4085198170592fabce4345745e49093822c95 100644 (file)
@@ -101,7 +101,6 @@ class CrossPlatformDistributionBuilder {
         }
         zipfileset(dir: "$macDistPath/bin", prefix: "bin", filemode: "775") {
           include(name: "restarter*")
-          include(name: "*.py")
         }
         zipfileset(dir: "$macDistPath/bin", prefix: "bin/mac", filemode: "775") {
           include(name: "fsnotifier*")