nw-builder 3.5.6 → 3.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/CHANGELOG.md +128 -0
- package/.github/CODE_OF_CONDUCT.md +55 -0
- package/.github/ISSUE_TEMPLATE.md +17 -0
- package/{LICENSE → .github/LICENSE} +0 -0
- package/.github/PULL_REQUEST_TEMPLATE.md +5 -0
- package/.github/workflows/cd.yml +24 -0
- package/.github/workflows/ci.yml +30 -0
- package/README.md +169 -113
- package/bin/nwbuild.cjs +97 -0
- package/dist/index.cjs +1 -0
- package/lib/Version.cjs +81 -0
- package/lib/downloader.cjs +177 -0
- package/lib/index.cjs +1078 -0
- package/lib/platformOverrides.cjs +147 -0
- package/lib/platforms.cjs +141 -0
- package/lib/utils.cjs +293 -0
- package/lib/versions.cjs +206 -0
- package/package.json +94 -62
- package/src/index.js +2 -0
- package/src/schema/Platform.js +16 -0
- package/src/schema/index.js +3 -0
- package/src/utilities/checkCache.js +30 -0
- package/src/utilities/detectCurrentPlatform.js +24 -0
- package/src/utilities/index.js +4 -0
- package/test/demo/icon.icns +0 -0
- package/test/demo/icon.ico +0 -0
- package/test/demo/index.cjs +14 -0
- package/test/demo/index.html +10 -0
- package/test/demo/package.json +24 -0
- package/test/downloader.cjs +131 -0
- package/test/expected/README.md +7 -0
- package/test/expected/merged +1 -0
- package/test/expected/oneOveriddenRestNot/README.md +7 -0
- package/test/expected/oneOveriddenRestNot/osx32.json +9 -0
- package/test/expected/oneOveriddenRestNot/osx64.json +9 -0
- package/test/expected/osx-plist/1.plist +47 -0
- package/test/expected/osx-plist/2.plist +40 -0
- package/test/expected/osx-plist/README.md +7 -0
- package/test/expected/platformOverrides/README.md +7 -0
- package/test/expected/platformOverrides/linux32.json +13 -0
- package/test/expected/platformOverrides/linux64.json +9 -0
- package/test/expected/platformOverrides/osx32.json +12 -0
- package/test/expected/platformOverrides/osx64.json +12 -0
- package/test/expected/platformOverrides/win32.json +12 -0
- package/test/expected/platformOverrides/win64.json +12 -0
- package/test/fixtures/README.md +7 -0
- package/test/fixtures/invalid.json +3 -0
- package/test/fixtures/manifest/README.md +7 -0
- package/test/fixtures/manifest/versions.json +29 -0
- package/test/fixtures/nwapp/README.md +7 -0
- package/test/fixtures/nwapp/images/imagefile.img +1 -0
- package/test/fixtures/nwapp/index.html +13 -0
- package/test/fixtures/nwapp/javascript/bower_packages/simple/package.json +1 -0
- package/test/fixtures/nwapp/javascript/jsfile.js +1 -0
- package/test/fixtures/nwapp/package.json +5 -0
- package/test/fixtures/oneOveriddenRestNot/README.md +7 -0
- package/test/fixtures/oneOveriddenRestNot/package.json +16 -0
- package/test/fixtures/osx-plist/Info.plist +93 -0
- package/test/fixtures/osx-plist/README.md +7 -0
- package/test/fixtures/platformOverrides/README.md +7 -0
- package/test/fixtures/platformOverrides/package.json +72 -0
- package/test/fixtures/test-strip.zip +0 -0
- package/test/fixtures/test.tar.gz +0 -0
- package/test/fixtures/test.zip +0 -0
- package/test/fixtures/testVersions.html +74 -0
- package/test/nwBuilder.cjs +339 -0
- package/test/unit/checkCache.test.js +19 -0
- package/test/unit/checkCacheDir/v0.64.1/linux64/nw1.app +0 -0
- package/test/unit/checkCacheDir/v0.64.1/linux64/nw2.app +0 -0
- package/test/unit/detectCurrentPlatform.test.js +58 -0
- package/test/utils.cjs +310 -0
- package/test/versions.cjs +486 -0
- package/CHANGELOG.md +0 -83
- package/bin/README.md +0 -7
- package/bin/nwbuild +0 -101
- package/index.js +0 -1
- package/lib/README.md +0 -7
- package/lib/Version.js +0 -60
- package/lib/detectCurrentPlatform.js +0 -17
- package/lib/downloader.js +0 -192
- package/lib/index.js +0 -863
- package/lib/platforms.js +0 -76
- package/lib/utils.js +0 -249
- package/lib/versions.js +0 -198
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
# Change Log
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file and in the [Releases](https://github.com/nwjs-community/nw-builder/blob/develop/releases) section.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
|
6
|
+
and this project adheres to [Semantic Versioning](http://semver.org/).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
## Added
|
|
11
|
+
|
|
12
|
+
- Optional zip file merging for Windows and Linux [#567](https://github.com/nwjs-community/nw-builder/pull/567)
|
|
13
|
+
- Add code of conduct [#560](https://github.com/nwjs-community/nw-builder/pull/560)
|
|
14
|
+
|
|
15
|
+
## Changed
|
|
16
|
+
|
|
17
|
+
- Update contributing guide [#569](https://github.com/nwjs-community/nw-builder/pull/569)
|
|
18
|
+
- Switch from TypeScript to JSDocs [#568](https://github.com/nwjs-community/nw-builder/pull/568)
|
|
19
|
+
- Set window icon with `rcedit` [#566](https://github.com/nwjs-community/nw-builder/pull/566)
|
|
20
|
+
- Refactor `checkCache` [#565](https://github.com/nwjs-community/nw-builder/pull/565)
|
|
21
|
+
- Simplify demo
|
|
22
|
+
- Refactor `detectCurrentPlatform` [#564](https://github.com/nwjs-community/nw-builder/pull/564)
|
|
23
|
+
- Update dependencies [#561](https://github.com/nwjs-community/nw-builder/pull/561) [#532](https://github.com/nwjs-community/nw-builder/pull/532)
|
|
24
|
+
## Removed
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
## [3.6.0] - 2022-05-18
|
|
29
|
+
|
|
30
|
+
### Added
|
|
31
|
+
|
|
32
|
+
- GitHub Actions for CICD [#552](https://github.com/nwjs-community/nw-builder/pull/552)
|
|
33
|
+
- Support multiple locales on OSX [#389](https://github.com/nwjs-community/nw-builder/pull/389)
|
|
34
|
+
- Pull request and issue template [#553](https://github.com/nwjs-community/nw-builder/pull/553)
|
|
35
|
+
|
|
36
|
+
### Changed
|
|
37
|
+
|
|
38
|
+
- Dependencies [#550](https://github.com/nwjs-community/nw-builder/pull/550)
|
|
39
|
+
- Documentation [#540](https://github.com/nwjs-community/nw-builder/pull/540) [#553](https://github.com/nwjs-community/nw-builder/pull/553) [#555](https://github.com/nwjs-community/nw-builder/pull/555)
|
|
40
|
+
- Improve run mode by detecting current platform to prevent downloading additional binaries
|
|
41
|
+
|
|
42
|
+
### Removed
|
|
43
|
+
|
|
44
|
+
- Travis
|
|
45
|
+
- AppVeyor
|
|
46
|
+
- JSHint
|
|
47
|
+
- EditorConfig
|
|
48
|
+
|
|
49
|
+
## [3.5.7]
|
|
50
|
+
|
|
51
|
+
### Security
|
|
52
|
+
|
|
53
|
+
- Source platform overrides module into the project instead of it being an extenal dependency. This helped us get rid of a vulnerable lodash version. See https://github.com/nwjs-community/nw-builder/issues/500
|
|
54
|
+
|
|
55
|
+
## [3.5.1] - 2017-10-19
|
|
56
|
+
|
|
57
|
+
### Added
|
|
58
|
+
|
|
59
|
+
- Add option.winVersionString for accurate process name. See https://github.com/nwjs-community/nw-builder/pull/459.
|
|
60
|
+
|
|
61
|
+
### Fixed
|
|
62
|
+
|
|
63
|
+
- Small platform overrides fix. See https://github.com/nwjs-community/nw-builder/pull/477/files.
|
|
64
|
+
|
|
65
|
+
## [3.4.1] - 2017-06-05
|
|
66
|
+
|
|
67
|
+
### Removed
|
|
68
|
+
|
|
69
|
+
- The `bluebird` dependency. We're now using native promises instead.
|
|
70
|
+
|
|
71
|
+
## [3.4.0] - 2017-05-28
|
|
72
|
+
|
|
73
|
+
### Added
|
|
74
|
+
|
|
75
|
+
- If using the package programmatically and it's out of date, a message will be shown (this was always the case for the CLI).
|
|
76
|
+
- There is now a README in every directory (with at least a single sentence summarizing the directory) to help with onboarding contributors.
|
|
77
|
+
|
|
78
|
+
### Changed
|
|
79
|
+
|
|
80
|
+
- Some dependencies are updated.
|
|
81
|
+
|
|
82
|
+
### Removed
|
|
83
|
+
|
|
84
|
+
- `osx32` is removed from the default list of platforms. Thanks to [@preaction](https://github.compreaction) (PR [#439](https://github.com/nwjs-community/nw-builder/pull/439)).
|
|
85
|
+
- An unnecessary `rcedit` dependency is removed.
|
|
86
|
+
|
|
87
|
+
### Fixed
|
|
88
|
+
|
|
89
|
+
- For Node 7+ users, you won't see a `os.tmpDir` deprecation warning anymore.
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
## Old format
|
|
94
|
+
|
|
95
|
+
- 2017-05-22 `3.2.3` Fix for caching when a version is specified (thanks @piwonesien for the help).
|
|
96
|
+
- 2017-05-20 `3.2.2` Fix: when using the `nwbuild` in run mode, the `-p` option was ignored and the current platform was always used.
|
|
97
|
+
- 2017-05-16 `3.2.1` Fix: NW.js 0.22.0+ apps didn't open.
|
|
98
|
+
- 2017-02-12 `3.2.0` Defaults to HTTPS now, added `manifestUrl` option, and bumped some dependencies.
|
|
99
|
+
- 2016-10-09 `3.1.2` Fix for passing array as files option when running app (plus some security fixes).
|
|
100
|
+
- 2016-10-09 `3.1.1` Fix for flavor feature when using CLI.
|
|
101
|
+
- 2016-09-14 `3.1.0` Ability to select any flavor of NW.js, not just `sdk`.
|
|
102
|
+
- 2016-08-28 `3.0.0` bumping graceful-fs-extra dependency to 2.0.0.
|
|
103
|
+
- 2016-08-14 `2.2.7` fix for macIcns option when using NW.js 0.12.3
|
|
104
|
+
- 2016-07-31 `2.2.6` fix for OS X caching
|
|
105
|
+
- 2016-07-03 `2.2.5` fix for update-notifier usage in bin
|
|
106
|
+
- 2016-07-03 `2.2.4` fix for syntax error in CLI
|
|
107
|
+
- 2016-07-02 `2.2.3` a few small fixes for the run option and more
|
|
108
|
+
- 2016-07-02 `2.2.2` fix for cache check of some legacy versions
|
|
109
|
+
- 2016-07-02 `2.2.1` supports newer NW.js versions (via http://nwjs.io/versions.json), plus other fixes.
|
|
110
|
+
- 2015-12-18 `2.2.0` added `zip` option.
|
|
111
|
+
- 2015-12-06 `2.1.0` added `cacheDir` command-line option, fix for no info being passed back, etc.
|
|
112
|
+
- 2015-06-28 `2.0.2` put upper bound to semver check for windows.
|
|
113
|
+
- 2015-06-14 `2.0.1` safer validation of versions.
|
|
114
|
+
- 2015-06-14 `2.0.0` changed to nw-builder, etc.
|
|
115
|
+
- 2015-05-05 `1.0.12` when using latest NW.js version, it's first validated that it's not an alpha version (fixes [#222](https://github.com/nwjs/nw-builder/issues/222)). Plus a fix for the `winIco` & `macIcns` command line options
|
|
116
|
+
- 2015-01-29 `1.0.8` fixed EMFILE errors (see [#147](https://github.com/nwjs/nw-builder/issues/147) [#148](https://github.com/nwjs/nw-builder/pull/148))
|
|
117
|
+
- 2015-01-21 `1.0.7` fixed about screen when copyright is not supplied
|
|
118
|
+
- 2015-01-15 `1.0.6` fixed downloads for nw.js version 0.12.0-alpha1
|
|
119
|
+
- 2015-01-15 `1.0.5` fixed downloads for NW.js versions < 0.12.0-alpha
|
|
120
|
+
- 2014-12-12 `1.0.0` 64-bit support, improved platform-overrides and no more EMFILE errors.
|
|
121
|
+
- 2014-12-07 `0.4.0` macPlist CFBundleIdentifier is generated from `package.json` (see [#131](https://github.com/nwjs/nw-builder/pull/131))
|
|
122
|
+
- 2014-11-14 `0.3.0` macPlist option improvements (see [#96](https://github.com/nwjs/nw-builder/pull/96))
|
|
123
|
+
- 2014-10-30 `0.2.0` adds support for platform-specific manifest overrides (see [#94](https://github.com/nwjs/nw-builder/pull/94))
|
|
124
|
+
- 2014-08-19 `0.1.2` adds a progress bar to downloads, fixes downloading through a proxy, fixed winIco, bug fixes
|
|
125
|
+
- 2014-08-01 `0.1.0` use app filename for generated executables, optimized version checking, (known issue: `winIco` on windows)
|
|
126
|
+
- 2014-07-31 `0.0.4` fixed compatibility with nodewebkit 0.10.0
|
|
127
|
+
- 2014-04-20 Added run option, bug fixes
|
|
128
|
+
- 2014-04-13 Preview Release
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# "No Ideologies" Code of Conduct
|
|
2
|
+
|
|
3
|
+
The following are the guidelines we expect our community members and maintainers to follow.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Terminology and Scope
|
|
8
|
+
|
|
9
|
+
**What defines a "maintainer"?**
|
|
10
|
+
|
|
11
|
+
- A maintainer is anyone that interacts with the community on behalf of this project. Amount of code written is not a qualifier. A maintainer may include those who solely help in support roles such as in resolving issues, improving documentation, administrating or moderating forums/chatrooms, or any other non-coding specific roles. Maintainers also include those that are responsible for the building and upkeep of the project.
|
|
12
|
+
|
|
13
|
+
**What defines a "community member"?**
|
|
14
|
+
|
|
15
|
+
- Anyone interacting with this project directly, including maintainers.
|
|
16
|
+
|
|
17
|
+
**What is the scope of these guidelines?**
|
|
18
|
+
|
|
19
|
+
- These guidelines apply only to this project and forms of communication directly related to it, such as issue trackers, forums, chatrooms, and in person events specific to this project. If a member is violating these guidelines outside of this project or on other platforms, that is beyond our scope and any grievances should be handled on those platforms.
|
|
20
|
+
|
|
21
|
+
**Discussing the guidelines:**
|
|
22
|
+
|
|
23
|
+
- Discussions around these guidelines, improving, updating, or altering them, is permitted so long as the discussions do not violate any existing guidelines.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Guidelines
|
|
28
|
+
|
|
29
|
+
### Guidelines for community members
|
|
30
|
+
|
|
31
|
+
This project is technical in nature and not based around any particular non-technical ideology. As such, communication that is based primarily around ideologies unrelated to the technologies used by this repository are not permitted.
|
|
32
|
+
|
|
33
|
+
Any discussion or communication that is primarily focused around an ideology, be it about race, gender, politics, religion, or anything else non-technical, is not allowed. Everyone has their own ideological preferences, beliefs, and opinions. We do not seek to marginalize, exclude, or judge anyone for their ideologies. To prevent conflict between those with differing or opposing ideologies, all communication on these subjects are prohibited. Some discussions around these topics may be important, however this project is not the proper channel for these discussions.
|
|
34
|
+
|
|
35
|
+
### Guidelines for maintainers
|
|
36
|
+
|
|
37
|
+
- Maintainers must abide by the same rules as all other community members mentioned above. However, in addition, maintainers are held to a higher standard, explained below.
|
|
38
|
+
- Maintainers should answer all questions politely.
|
|
39
|
+
- If someone is upset or angry about something, it's probably because it's difficult to use, so thank them for bringing it to your attention and address ways to solve the problem. Maintainers should focus on the content of the message, and not on how it was delivered.
|
|
40
|
+
- A maintainer should seek to update members when an issue they brought up is resolved.
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## Appropriate response to violations
|
|
45
|
+
|
|
46
|
+
How to respond to a community member or maintainer violating a guideline.
|
|
47
|
+
|
|
48
|
+
1. If an issue is created that violates a guideline a maintainer should close and lock the issue, explaining "This issue is in violation of our code of conduct. Please review it before posting again." with a link to this document.
|
|
49
|
+
1. If a member repeatedly violates the guidelines established in this document, they should be politely warned that continuing to violate the rules may result in being banned from the community. This means revoking access and support to interactions relating directly to the project (issue trackers, chatrooms, forums, in person events, etc.). However, they may continue to use the technology in accordance with its license.
|
|
50
|
+
1. If a maintainer is in violation of a guideline, they should be informed of such with a link to this document. If additional actions are required of the maintainer but not taken, then other maintainers should be informed of these inactions.
|
|
51
|
+
1. If a maintainer repeatedly violates the guidelines established in this document, they should be politely warned that continuing to violate the rules may result in being banned from the community. This means revoking access and support to interactions relating directly to the project (issue trackers, chatrooms, forums, in person events, etc.). However, they may continue to use the technology in accordance with its license. In addition, future contributions to this project may be ignored as well.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
Based on version 1.0.3 from https://github.com/CodifiedConduct/coc-no-ideologies
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
### Issue Type
|
|
2
|
+
|
|
3
|
+
- [ ] Bug Fix
|
|
4
|
+
- [ ] Feature
|
|
5
|
+
- [ ] Other
|
|
6
|
+
|
|
7
|
+
### Current/Missing Behaviour
|
|
8
|
+
|
|
9
|
+
### Expected/Proposed Behaviour
|
|
10
|
+
|
|
11
|
+
### Additional Info
|
|
12
|
+
|
|
13
|
+
- Operating System:
|
|
14
|
+
- Node version:
|
|
15
|
+
- NW.js version:
|
|
16
|
+
- Repro link:
|
|
17
|
+
- ...
|
|
File without changes
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
name: cd
|
|
2
|
+
on:
|
|
3
|
+
push:
|
|
4
|
+
branches:
|
|
5
|
+
- master
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
publish:
|
|
9
|
+
runs-on: ubuntu-latest
|
|
10
|
+
steps:
|
|
11
|
+
- uses: actions/checkout@v3
|
|
12
|
+
- uses: pnpm/action-setup@v2.2.1
|
|
13
|
+
with:
|
|
14
|
+
version: 7.1.0
|
|
15
|
+
run_install: true
|
|
16
|
+
|
|
17
|
+
- uses: actions/setup-node@v2
|
|
18
|
+
with:
|
|
19
|
+
node-version: "16"
|
|
20
|
+
|
|
21
|
+
- run: pnpm install
|
|
22
|
+
- uses: JS-DevTools/npm-publish@v1
|
|
23
|
+
with:
|
|
24
|
+
token: ${{ secrets.NPM_TOKEN }}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
name: ci
|
|
2
|
+
on:
|
|
3
|
+
pull_request:
|
|
4
|
+
branches:
|
|
5
|
+
- master
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
branches:
|
|
8
|
+
- master
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
test:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
strategy:
|
|
14
|
+
matrix:
|
|
15
|
+
node: [14, 16, 18]
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v3
|
|
18
|
+
- uses: pnpm/action-setup@v2.2.1
|
|
19
|
+
with:
|
|
20
|
+
version: 7.1.0
|
|
21
|
+
run_install: true
|
|
22
|
+
|
|
23
|
+
- uses: actions/setup-node@v3
|
|
24
|
+
with:
|
|
25
|
+
node-version: ${{ matrix.node }}
|
|
26
|
+
|
|
27
|
+
- run: pnpm install
|
|
28
|
+
- run: pnpm format
|
|
29
|
+
- run: pnpm lint
|
|
30
|
+
- run: pnpm test
|