You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2018/04/29 12:53:55 UTC
[GitHub] matthiasblaesing closed pull request #404: [NETBEANS-341] Added
initial files required for Snap packaging
matthiasblaesing closed pull request #404: [NETBEANS-341] Added initial files required for Snap packaging
URL: https://github.com/apache/incubator-netbeans/pull/404
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git a/.gitignore b/.gitignore
index bcd6d424e..345a4de93 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,3 +41,12 @@
/xml/test/qa-functional/data/ActionsTestProject/nbproject/private/
/xml/test/qa-functional/data/CoreTemplatesTestProject/nbproject/private/
/javafx2.samples/FXML-LoginDemo/nbproject/private/
+
+# Snapcraft Generated files #
+#######################
+/nbbuild/packaging/snap/.snapcraft/
+/nbbuild/packaging/parts/
+/nbbuild/packaging/prime/
+/nbbuild/packaging/stage/
+*.snap
+
diff --git a/nbbuild/packaging/snap/gui/netbeans.desktop b/nbbuild/packaging/snap/gui/netbeans.desktop
new file mode 100644
index 000000000..a87203725
--- /dev/null
+++ b/nbbuild/packaging/snap/gui/netbeans.desktop
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+[Desktop Entry]
+Type=Application
+Encoding=UTF-8
+Name=NetBeans Dev
+Comment=The Smarter Way to Code
+Exec=netbeans %F
+Categories=Application;Development;Java;IDE
+Icon=${SNAP}/meta/gui/icon.png
+Terminal=false
diff --git a/nbbuild/packaging/snap/snapcraft.yaml b/nbbuild/packaging/snap/snapcraft.yaml
new file mode 100644
index 000000000..bb9be08ea
--- /dev/null
+++ b/nbbuild/packaging/snap/snapcraft.yaml
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: netbeans
+version: "9.0-dev"
+summary: NetBeans Java IDE
+description: |
+ NetBeans IDE lets you quickly and easily develop Java desktop, mobile, and
+ web applications, as well as HTML5 applications with HTML, JavaScript, and
+ CSS. The IDE also provides a great set of tools for PHP and C/C++ developers.
+ It is free and open source and has a large community of users and developers
+ around the world.
+icon: ../../ide.branding/release/netbeans.png
+confinement: classic
+grade: devel
+architectures: [ amd64 ]
+
+parts:
+ build:
+ build-packages:
+ - openjdk-8-jdk-headless
+ - ant
+ build: |
+ JAVA_HOME="/usr/lib/jvm/java-8-openjdk-amd64"
+ export JAVA_HOME
+ ant -quiet -Djavac.compilerargs=-nowarn -Dbuild.compiler.deprecation=false
+ build-attributes: [ no-patchelf ]
+ plugin: nil
+ source: ../../
+ filesets:
+ netbeans: [ netbeans/*, -netbeans/*.built ]
+ install: |
+ mv nbbuild/netbeans $SNAPCRAFT_PART_INSTALL/netbeans
+ # Make the default cache and data directory relative to Snap user directory
+ sed -i 's/${HOME}\/.netbeans/${SNAP_USER_COMMON}\/data/' $SNAPCRAFT_PART_INSTALL/netbeans/bin/netbeans
+ sed -i 's/${HOME}\/.cache\/netbeans/${SNAP_USER_COMMON}\/cache/' $SNAPCRAFT_PART_INSTALL/netbeans/bin/netbeans
+ stage:
+ - $netbeans
+
+apps:
+ netbeans:
+ command: netbeans/bin/netbeans
+
+
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists