Skip to content

Commit 7bd1cff

Browse files
committed
Publish v2.0.0
1 parent 5a100cd commit 7bd1cff

File tree

4 files changed

+43
-31
lines changed

4 files changed

+43
-31
lines changed

.travis.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,30 @@ matrix:
33
- stage: "Lint"
44
language: node_js
55
os: linux
6-
node_js: "8"
7-
script: cd src && npm run ci.tslint && cd ../demo && npm run ci.tslint
6+
node_js: "10"
7+
script: cd src && npm run ci.tslint
88
- stage: "WebPack, Build and Test"
99
os: osx
1010
env:
1111
- WebPack="iOS"
1212
osx_image: xcode10.0
1313
language: node_js
14-
node_js: "8"
14+
node_js: "10"
1515
jdk: oraclejdk8
16-
script: cd demo && npm run build.plugin && npm i && tns build ios --bundle --env.uglify
16+
script: cd src && npm run build && cd ../demo && npm i && tns build ios --bundle --env.uglify
1717
- language: android
1818
os: linux
1919
env:
2020
- WebPack="Android"
2121
jdk: oraclejdk8
22-
before_install: nvm install 8
23-
script: cd demo && npm run build.plugin && npm i && tns build android --bundle --env.uglify --env.snapshot
22+
before_install: nvm install 10
23+
script: cd src && npm run build && cd ../demo && npm i && tns build android --bundle --env.uglify --env.snapshot
2424
- language: android
2525
env:
2626
- BuildAndroid="28"
2727
os: linux
2828
jdk: oraclejdk8
29-
before_install: nvm install stable
29+
before_install: nvm install 10
3030
script:
3131
- cd src && npm i && npm run tsc && cd ../demo && tns build android
3232
- os: osx
@@ -35,7 +35,7 @@ matrix:
3535
- Xcode="10.0"
3636
osx_image: xcode10.0
3737
language: node_js
38-
node_js: "8"
38+
node_js: "10"
3939
jdk: oraclejdk8
4040
script:
4141
- cd src && npm i && npm run tsc && cd ../demo && tns build ios
@@ -54,7 +54,7 @@ matrix:
5454
# script: cd src && npm run test.android
5555
# - os: osx
5656
# language: node_js
57-
# node_js: "8"
57+
# node_js: "10"
5858
# jdk: oraclejdk8
5959
# osx_image: xcode10.0
6060
# script: cd src && npm run test.ios

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ in case of vulnerabilities.
2121
-->
2222

2323
## [Unreleased]
24+
25+
## [2.0.0] - 2019-07-27
2426
### Added
2527
- **Android:** Migrate to AndroidX by [@jdnichollsc].
2628
- Include a **CHANGELOG.md** to see the history of the changes of the project.
@@ -40,5 +42,6 @@ in case of vulnerabilities.
4042
- Methods to open and close external urls to authenticate the user **(openAuth, closeAuth)** using deep linking.
4143
- `isAvailable` method to detect if the device supports the plugin.
4244

43-
[Unreleased]: https://github.com/proyecto26/nativescript-inappbrowser/compare/v1.0.0...HEAD
45+
[Unreleased]: https://github.com/proyecto26/nativescript-inappbrowser/compare/v2.0.0...HEAD
46+
[2.0.0]: https://github.com/proyecto26/react-native-inappbrowser/compare/v1.0.0...v2.0.0
4447
[1.0.0]: https://github.com/proyecto26/nativescript-inappbrowser/releases/tag/v1.0.0

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ Property | Description
7171
`enableDefaultShare` (Boolean) | Adds a default share item to the menu. [`true`/`false`]
7272
`animations` (Object) | Sets the start and exit animations. [`{ startEnter, startExit, endEnter, endExit }`]
7373
`headers` (Object) | The data are key/value pairs, they will be sent in the HTTP request headers for the provided url. [`{ 'Authorization': 'Bearer ...' }`]
74-
`forceCloseOnRedirection` (Boolean) | Open Custom Tab in new task to avoid issues redirecting back to app scheme. [`true`/`false`]
74+
`forceCloseOnRedirection` (Boolean) | Open Custom Tab in a new task to avoid issues redirecting back to app scheme. [`true`/`false`]
7575

7676
### Demo
7777

src/scripts/build-native.js

Lines changed: 29 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,33 @@
1-
const { exec } = require('child_process');
2-
const semver = require('semver');
1+
const { exec } = require('child_process')
2+
const semver = require('semver')
33

44
exec('tns --version', (err, stdout, stderr) => {
5-
if (err) {
6-
// node couldn't execute the command
7-
console.log(`tns --version err: ${err}`);
8-
return;
9-
}
5+
if (err) {
6+
// node couldn't execute the command
7+
console.log(`tns --version err: ${err}`)
8+
return
9+
}
10+
11+
// In case the current Node.js version is not supported by CLI, a warning in `tns --version` output is shown.
12+
// Sample output:
13+
//
14+
/* Support for Node.js ^8.0.0 is deprecated and will be removed in one of the next releases of NativeScript. Please, upgrade to the latest Node.js LTS version.
1015
11-
const tnsVersion = semver.major(stdout);
16+
6.0.0
17+
*/
18+
// Extract the actual version (6.0.0) from it.
19+
const tnsVersion = semver.major(
20+
(stdout.match(/^(?:\d+\.){2}\d+.*?$/m) || [])[0]
21+
)
1222

13-
// execute 'tns plugin build' for {N} version > 4. This command builds .aar in platforms/android folder.
14-
if (tnsVersion >= 4) {
15-
console.log(`executing 'tns plugin build'`);
16-
exec('tns plugin build', (err, stdout, stderr) => {
17-
if (err) {
18-
// node couldn't execute the command
19-
console.log(`${err}`);
20-
return;
21-
}
22-
});
23-
}
24-
});
23+
// execute 'tns plugin build' for {N} version > 4. This command builds .aar in platforms/android folder.
24+
if (tnsVersion >= 4) {
25+
console.log(`executing 'tns plugin build'`)
26+
exec('tns plugin build', (err, stdout, stderr) => {
27+
if (err) {
28+
// node couldn't execute the command
29+
console.log(`${err}`)
30+
}
31+
})
32+
}
33+
})

0 commit comments

Comments
 (0)