Changeset 17236 in josm
- Timestamp:
- 2020-10-18T15:34:35+02:00 (4 years ago)
- Location:
- trunk
- Files:
-
- 1 deleted
- 5 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/.github/workflows/ant.yml
r17156 r17236 1 1 name: Java CI 2 2 env: 3 junit_platform_version: '1.7.0' 3 4 # ANT_HOME is also our ant version 4 ANT_HOME: "apache-ant-1.10.8"5 ANT_HOME: 'apache-ant-1.10.9' 5 6 on: 6 7 push: … … 22 23 matrix: 23 24 # test against latest update of each major Java version, as well as specific updates of LTS versions: 24 java: [8, 11, 14 ]25 java: [8, 11, 14, 15, 16-ea] 25 26 os: [ubuntu-latest, macos-latest, windows-latest] 26 27 headless: ["true", "false"] … … 39 40 uses: actions/checkout@v2 40 41 with: 41 fetch-depth: 6442 fetch-depth: 128 42 43 - name: Cache 43 44 uses: actions/cache@v2.0.0 44 45 with: 45 path: |46 path: | 46 47 ~/.ivy2/cache/ 47 48 ~/work/josm/josm/tools/ 48 49 key: ${{ runner.os }}-ivy2-${{ hashFiles('ivy.xml') }} 49 50 - name: Setup java 50 uses: actions/setup-java@v1. 3.051 uses: actions/setup-java@v1.4.3 51 52 with: 52 53 java-version: ${{ matrix.java }} 53 - name: Install ant ${{ env.ANT_HOME }} 54 - name: Install ant ${{ env.ANT_HOME }} and junit ${{ env.junit_platform_version }} 55 # Todo: cache ant and junit, saves 12 seconds. 54 56 run: | 55 curl -s https://archive.apache.org/dist/ant/binaries/${{ env.ANT_HOME }}-bin.tar.gz | tar -xz 57 curl -s https://downloads.apache.org/ant/binaries/${{ env.ANT_HOME }}-bin.tar.gz | tar -xz 58 curl -o ${{ env.ANT_HOME }}/lib/junit-platform-console-standalone-${{ env.junit_platform_version }}.jar "https://repo1.maven.org/maven2/org/junit/platform/junit-platform-console-standalone/${{ env.junit_platform_version }}/junit-platform-console-standalone-${{ env.junit_platform_version }}.jar" 56 59 - name: Print ant version, expecting ${{ env.ANT_HOME }} 57 run: ${{ env.ANT_HOME }}/bin/ant -diagnostics 60 run: ${{ env.ANT_HOME }}/bin/ant -version 61 - name: Set revision env variable 62 run: | 63 ant create-revision 64 josm_revision=`awk '/Revision/{print $2}' resources/REVISION` 65 if [[ "$josm_revision" == `curl --silent https://josm.openstreetmap.de/tested` ]]; then 66 sed -i .bak '/Is-Local-Build/d' resources/REVISION 67 echo "josm_prerelease=false" >> $GITHUB_ENV 68 else 69 echo "josm_prerelease=true" >> $GITHUB_ENV 70 fi 71 echo "josm_revision=$josm_revision" >> $GITHUB_ENV 58 72 - name: Build with Ant, headless ${{ matrix.headless }} 59 73 run: | … … 67 81 if: ${{ failure() }} 68 82 run: "grep -L ', Failures: 0, Skipped: ' test/report/*.txt | xargs cat" 69 - name: Set revision env variable70 if: ${{ always() }}71 # Careful, you will only have a resources/REVISION if you've already built72 run: echo "::set-env name=josm_revision::`awk '/Revision/{print $2}' resources/REVISION`"73 83 - name: Upload Ant reports 74 84 if: ${{ always() }} … … 77 87 name: Ant reports for JOSM ${{ env.josm_revision }} on java ${{ matrix.java }} on ${{ matrix.os }} with headless=${{ matrix.headless }} 78 88 path: test/report/*.txt 89 - name: Optimise images 90 if: ${{ runner.os == 'macos' && always() }} 91 run: | 92 brew cask install imageoptim 93 defaults write net.pornel.ImageOptim SvgoEnabled 1 94 defaults write net.pornel.ImageOptim PngCrush2Enabled 1 95 defaults write net.pornel.ImageOptim PngOutEnabled 1 96 /Applications/ImageOptim.app/Contents/MacOS/ImageOptim resources/images 79 97 - name: Build and package for macOS 80 98 if: ${{ runner.os == 'macos' && always() }} … … 86 104 $ANT_HOME/bin/ant dist 87 105 ./native/macosx/macos-jpackage.sh ${{ env.josm_revision }} 88 - name: Upload JOSM.app for macOS106 - name: Create macOS release 89 107 if: ${{ runner.os == 'macos' && always() }} 90 uses: actions/upload-artifact@v2 108 id: create_release 109 uses: actions/create-release@v1 110 env: 111 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token 91 112 with: 92 name: JOSM.app revision ${{ env.josm_revision }} 93 path: dist/JOSM.zip 113 tag_name: ${{ env.josm_revision }} 114 release_name: JOSM.app release ${{ env.josm_revision }} 115 body: | 116 JOSM.app release ${{ env.josm_revision }} 117 draft: false 118 prerelease: ${{ env.josm_prerelease }} 119 - name: Upload app 120 if: ${{ runner.os == 'macos' && always() }} 121 id: upload-app 122 uses: actions/upload-release-asset@v1 123 env: 124 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 125 with: 126 upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing its ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps 127 asset_path: dist/JOSM.zip 128 asset_name: JOSM-${{ runner.os}}-java${{ matrix.java }}.zip 129 asset_content_type: application/zip 130 - name: Upload jar 131 if: ${{ runner.os == 'macos' && always() }} 132 id: upload-jar 133 uses: actions/upload-release-asset@v1 134 env: 135 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 136 with: 137 upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing its ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps 138 asset_path: dist/josm-custom.jar 139 asset_name: josm-latest.jar 140 asset_content_type: application/java-archive -
trunk/build.xml
r16908 r17236 194 194 shortversion="${version.entry.commit.revision} SVN" 195 195 version="${version.entry.commit.revision} SVN" 196 icon="native/macosx/JOSM. app/Contents/Resources/JOSM.icns"196 icon="native/macosx/JOSM.icns" 197 197 highResolutionCapable="true"> 198 198 -
trunk/native/macosx/gz.properties
r16776 r17236 1 1 extension=gz 2 2 mime-type=application/gzip 3 description=OpenStreetMap BZipped3 description=OpenStreetMap GZipped -
trunk/native/macosx/jos.properties
r16776 r17236 1 extension=jo z1 extension=jos 2 2 mime-type=application/x-josm-session+xml 3 3 description=JOSM Session -
trunk/native/macosx/macos-jpackage.sh
r16785 r17236 19 19 jpackage -n "JOSM" --input dist --main-jar josm-custom.jar \ 20 20 --main-class org.openstreetmap.josm.gui.MainApplication \ 21 --icon native/macosx/JOSM.app/Contents/Resources/JOSM.icns --type app-image --dest dist \21 --icon ./native/macosx/JOSM.icns --type app-image --dest dist \ 22 22 --java-options "-Xmx8192m" --app-version $1 \ 23 23 --copyright "JOSM, and all its integral parts, are released under the GNU General Public License v2 or later" \ … … 80 80 81 81 echo "Preparing for notarization" 82 ditto -c -k -- keepParent dist/JOSM.app dist/JOSM.zip82 ditto -c -k --zlibCompressionLevel 9 --keepParent dist/JOSM.app dist/JOSM.zip 83 83 84 84 echo "Uploading to Apple" 85 85 xcrun altool --notarize-app -f dist/JOSM.zip -p "$APPLE_ID_PW" -u "thomas.skowron@fossgis.de" --primary-bundle-id de.openstreetmap.josm 86 87 # Prepare for upload-artifact88 mkdir dist-macOS89 unzip dist/JOSM.zip -d dist-macOS
Note:
See TracChangeset
for help on using the changeset viewer.