Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ccdffbfebd | ||
|
|
e0efdc34da | ||
|
|
58f0523a41 | ||
|
|
b41fa9884b |
@@ -41,20 +41,21 @@
|
||||
"identityName": "51031thomas.nordquist.MQTT-Explorer",
|
||||
"publisherDisplayName": "Thomas Nordquist",
|
||||
"publisher": "CN=0A6DE643-4AA2-4FF2-9729-6935C9ED8C13",
|
||||
"backgroundColor": "#FFFFFF"
|
||||
"backgroundColor": "transparent"
|
||||
},
|
||||
"directories": {
|
||||
"app": "./",
|
||||
"buildResources": "res",
|
||||
"output": "build"
|
||||
},
|
||||
"afterAllArtifactBuild": "./dist/scripts/afterPack.js"
|
||||
"afterAllArtifactBuild": "./dist/scripts/afterAllArtifactBuild.js"
|
||||
},
|
||||
"author": "Thomas Nordquist",
|
||||
"email": "xxnerowingerxx@gmail.com",
|
||||
"homepage": "https://github.com",
|
||||
"license": "ISC",
|
||||
"devDependencies": {
|
||||
"@types/adm-zip": "^0.4.32",
|
||||
"@types/chai": "^4.1.7",
|
||||
"@types/fs-extra": "^5.0.5",
|
||||
"@types/lowdb": "^1.0.6",
|
||||
@@ -64,6 +65,7 @@
|
||||
"@types/node": "^10.12.18",
|
||||
"@types/semver": "^5.5.0",
|
||||
"@types/sha1": "^1.1.1",
|
||||
"adm-zip": "^0.4.13",
|
||||
"axios": "^0.18.0",
|
||||
"chai": "^4.2.0",
|
||||
"electron": "^4.0.6",
|
||||
|
||||
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 42 KiB |
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 61 KiB |
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 9.7 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 43 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
@@ -0,0 +1,41 @@
|
||||
BASE_IMAGE=icon.png
|
||||
|
||||
function scale44() {
|
||||
convert $BASE_IMAGE -resize "$1"x"$1" appx/Square44x44Logo.targetsize-"$1"_altform-unplated.png
|
||||
convert $BASE_IMAGE -resize "$1"x"$1" -resize 66% -gravity center -background transparent -extent "$1"x"$1" appx/Square44x44Logo.targetsize-"$1".png
|
||||
}
|
||||
|
||||
function storeLogo() {
|
||||
SCALE=$1
|
||||
PIXELS=$2
|
||||
convert $BASE_IMAGE -resize "$PIXELS"x"$PIXELS" appx/StoreLogo-scale-"$SCALE"_altform-unplated.png
|
||||
}
|
||||
|
||||
function store150() {
|
||||
SCALE=$1
|
||||
PIXELS=$2
|
||||
PIXELSx2=$[ $2 * 2 ]
|
||||
convert $BASE_IMAGE -gravity center -resize "$PIXELS"x"$PIXELS" -resize 50% -extent "$PIXELS"x"$PIXELS" appx/Square150x150Logo-scale-$SCALE.png
|
||||
convert $BASE_IMAGE -gravity center -resize "$PIXELS"x"$PIXELS" -resize 50% -extent "$PIXELS"x"$PIXELSx2" appx/Square150x300Logo-scale-$SCALE.png
|
||||
}
|
||||
|
||||
# Create Square44x44Logo
|
||||
convert $BASE_IMAGE -resize 44x44 appx/Square44x44Logo.png
|
||||
scale44 16
|
||||
scale44 24
|
||||
scale44 32
|
||||
scale44 48
|
||||
scale44 256
|
||||
|
||||
store150 100 150
|
||||
store150 150 225
|
||||
store150 200 300
|
||||
store150 300 450
|
||||
store150 400 600
|
||||
|
||||
storeLogo 100 50
|
||||
storeLogo 150 75
|
||||
storeLogo 200 100
|
||||
storeLogo 400 200
|
||||
convert $BASE_IMAGE -resize 50x50 appx/StoreLogo.png
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
import * as fs from 'fs-extra'
|
||||
import * as path from 'path'
|
||||
import { chdir } from 'process'
|
||||
import { exec } from './util'
|
||||
import * as AdmZip from 'adm-zip'
|
||||
|
||||
export default async function (info: any) {
|
||||
for (const artifact of info.artifactPaths) {
|
||||
if (/\.snap$/.test(artifact)) {
|
||||
const originalDir = __dirname
|
||||
const dirname = path.dirname(artifact)
|
||||
chdir(dirname)
|
||||
|
||||
await exec('sudo', ['unsquashfs', artifact])
|
||||
await fs.remove(artifact)
|
||||
await exec('sudo', ['chmod', '-R', 'g-s', 'squashfs-root'])
|
||||
await exec('sudo', ['snap', 'run', 'snapcraft', 'pack', 'squashfs-root', '--output', artifact])
|
||||
await fs.remove('squashfs-root')
|
||||
|
||||
chdir(originalDir)
|
||||
}
|
||||
|
||||
if (/\.appx$/.test(artifact)) {
|
||||
const zip = new AdmZip(artifact)
|
||||
const data = zip.readAsText('AppxManifest.xml')
|
||||
const newData = data.replace('uap:DefaultTile', 'uap:DefaultTile ShowName="allLogos"')
|
||||
zip.updateFile('AppxManifest.xml', Buffer.from(newData))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
import * as fs from 'fs-extra'
|
||||
import * as path from 'path'
|
||||
import { chdir } from 'process'
|
||||
import { exec } from './util'
|
||||
|
||||
export default async function (info: any) {
|
||||
for (const snapFile of info.artifactPaths) {
|
||||
if (/\.snap$/.test(snapFile)) {
|
||||
const originalDir = __dirname
|
||||
const dirname = path.dirname(snapFile)
|
||||
chdir(dirname)
|
||||
|
||||
await exec('sudo', ['unsquashfs', snapFile])
|
||||
await fs.remove(snapFile)
|
||||
await exec('sudo', ['chmod', '-R', 'g-s', 'squashfs-root'])
|
||||
await exec('sudo', ['snap', 'run', 'snapcraft', 'pack', 'squashfs-root', '--output', snapFile])
|
||||
await fs.remove('squashfs-root')
|
||||
|
||||
chdir(originalDir)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -114,6 +114,13 @@
|
||||
reflect-metadata "^0.1.12"
|
||||
tslib "^1.8.1"
|
||||
|
||||
"@types/adm-zip@^0.4.32":
|
||||
version "0.4.32"
|
||||
resolved "https://registry.yarnpkg.com/@types/adm-zip/-/adm-zip-0.4.32.tgz#6de01309af60677065d2e52b417a023303220931"
|
||||
integrity sha512-hv1O7ySn+XvP5OeDQcJFWwVb2v+GFGO1A9aMTQ5B/bzxb7WW21O8iRhVdsKKr8QwuiagzGmPP+gsUAYZ6bRddQ==
|
||||
dependencies:
|
||||
"@types/node" "*"
|
||||
|
||||
"@types/chai@^4.1.7":
|
||||
version "4.1.7"
|
||||
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.1.7.tgz#1b8e33b61a8c09cbe1f85133071baa0dbf9fa71a"
|
||||
@@ -201,6 +208,11 @@ about-window@^1.12.1:
|
||||
resolved "https://registry.yarnpkg.com/about-window/-/about-window-1.12.1.tgz#b81c10f6de58d38bce2aa5f31f61a82e6c3d6c2b"
|
||||
integrity sha512-P/fJACq7RBFpv5Ql0kIqpOYgFqQ8WdoZoB7wrKmDvwTSKVOMbUZMYnQYtnOW6dHmMCYuNrmQFf+MxvuhE+KrzQ==
|
||||
|
||||
adm-zip@^0.4.13:
|
||||
version "0.4.13"
|
||||
resolved "https://registry.yarnpkg.com/adm-zip/-/adm-zip-0.4.13.tgz#597e2f8cc3672151e1307d3e95cddbc75672314a"
|
||||
integrity sha512-fERNJX8sOXfel6qCBCMPvZLzENBEhZTzKqg6vrOW5pvoEaQuJhRU4ndTAh6lHOxn1I6jnz2NHra56ZODM751uw==
|
||||
|
||||
ajv-keywords@^3.2.0:
|
||||
version "3.2.0"
|
||||
resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.2.0.tgz#e86b819c602cf8821ad637413698f1dec021847a"
|
||||
|
||||