-
-
Notifications
You must be signed in to change notification settings - Fork 119
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated Flatpak Appdata file, added script to bump version number
- Loading branch information
ransome1
committed
Oct 26, 2023
1 parent
fea5b62
commit 9970183
Showing
10 changed files
with
10,546 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
const fs = require('fs'); | ||
const packageJson = require('../../release/app/package.json'); | ||
const { format } = require('date-fns'); // You may need to install this library using `yarn add date-fns` if you haven't already. | ||
|
||
// Update the .flatpak/com.github.ransome1.sleek.desktop file | ||
let desktopContent = fs.readFileSync('../../flatpak/com.github.ransome1.sleek.desktop', 'utf8'); | ||
desktopContent = desktopContent.replace(/Version=.*\n/, `Version=${packageJson.version}\n`); | ||
fs.writeFileSync('../../flatpak/com.github.ransome1.sleek.desktop', desktopContent); | ||
|
||
console.log('Updated com.github.ransome1.sleek.desktop with version', packageJson.version); | ||
|
||
// Update the com.github.ransome1.sleek.appdata.xml file | ||
let appdataContent = fs.readFileSync('../../flatpak/com.github.ransome1.sleek.appdata.xml', 'utf8'); | ||
const today = new Date(); | ||
const formattedDate = format(today, 'yyyy-MM-dd'); | ||
appdataContent = appdataContent.replace(/<release version=".*?" date=".*?"\/>/, `<release version="${packageJson.version}" date="${formattedDate}"/>`); | ||
fs.writeFileSync('../../flatpak/com.github.ransome1.sleek.appdata.xml', appdataContent); | ||
|
||
console.log('Updated com.github.ransome1.sleek.appdata.xml with version', packageJson.version, 'and date', formattedDate); | ||
|
||
// Update the snapcraft.yaml file | ||
let snapcraftContent = fs.readFileSync('../../snap/snapcraft.yaml', 'utf8'); | ||
snapcraftContent = snapcraftContent.replace(/version: ".*?"/, `version: "${packageJson.version}"`); | ||
fs.writeFileSync('../../snap/snapcraft.yaml', snapcraftContent); | ||
|
||
console.log('Updated snapcraft.yaml with version', packageJson.version); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,6 +32,4 @@ npm-debug.log.* | |
*.dtmp | ||
*.drawio | ||
*.snap | ||
*FilterLang.js | ||
*.lock | ||
package-lock.json | ||
*FilterLang.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. | ||
# yarn lockfile v1 | ||
|
||
|
||
anymatch@~3.1.2: | ||
version "3.1.3" | ||
resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" | ||
integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== | ||
dependencies: | ||
normalize-path "^3.0.0" | ||
picomatch "^2.0.4" | ||
|
||
binary-extensions@^2.0.0: | ||
version "2.2.0" | ||
resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" | ||
integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== | ||
|
||
braces@~3.0.2: | ||
version "3.0.2" | ||
resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" | ||
integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== | ||
dependencies: | ||
fill-range "^7.0.1" | ||
|
||
chokidar@^3.5.3: | ||
version "3.5.3" | ||
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd" | ||
integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== | ||
dependencies: | ||
anymatch "~3.1.2" | ||
braces "~3.0.2" | ||
glob-parent "~5.1.2" | ||
is-binary-path "~2.1.0" | ||
is-glob "~4.0.1" | ||
normalize-path "~3.0.0" | ||
readdirp "~3.6.0" | ||
optionalDependencies: | ||
fsevents "~2.3.2" | ||
|
||
fill-range@^7.0.1: | ||
version "7.0.1" | ||
resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" | ||
integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== | ||
dependencies: | ||
to-regex-range "^5.0.1" | ||
|
||
fsevents@~2.3.2: | ||
version "2.3.3" | ||
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" | ||
integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== | ||
|
||
glob-parent@~5.1.2: | ||
version "5.1.2" | ||
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" | ||
integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== | ||
dependencies: | ||
is-glob "^4.0.1" | ||
|
||
is-binary-path@~2.1.0: | ||
version "2.1.0" | ||
resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" | ||
integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== | ||
dependencies: | ||
binary-extensions "^2.0.0" | ||
|
||
is-extglob@^2.1.1: | ||
version "2.1.1" | ||
resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" | ||
integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== | ||
|
||
is-glob@^4.0.1, is-glob@~4.0.1: | ||
version "4.0.3" | ||
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" | ||
integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== | ||
dependencies: | ||
is-extglob "^2.1.1" | ||
|
||
is-number@^7.0.0: | ||
version "7.0.0" | ||
resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" | ||
integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== | ||
|
||
normalize-path@^3.0.0, normalize-path@~3.0.0: | ||
version "3.0.0" | ||
resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" | ||
integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== | ||
|
||
picomatch@^2.0.4, picomatch@^2.2.1: | ||
version "2.3.1" | ||
resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" | ||
integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== | ||
|
||
readdirp@~3.6.0: | ||
version "3.6.0" | ||
resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" | ||
integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA== | ||
dependencies: | ||
picomatch "^2.2.1" | ||
|
||
to-regex-range@^5.0.1: | ||
version "5.0.1" | ||
resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" | ||
integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== | ||
dependencies: | ||
is-number "^7.0.0" |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.