fiftyone.geolocation 4.5.2 → 4.5.99
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/README.md +3 -3
- package/docs/Doxyfile +18 -18
- package/examples/51d.json +1 -1
- package/examples/combiningServices.js +4 -4
- package/examples/configureFromFile.js +3 -3
- package/examples/gettingStarted.js +4 -4
- package/examples/webIntegration.js +4 -4
- package/package.json +8 -7
- package/tsconfig.json +1 -0
- package/.github/workflows/monthly-copyright-update.yml +0 -21
- package/.github/workflows/nightly-pipeline.yml +0 -56
- package/.github/workflows/package-update.yml +0 -19
- package/.github/workflows/publish.yml +0 -22
- package/.github/workflows/pull-requests.yml +0 -21
- package/.gitmodules +0 -3
- package/ci/README.md +0 -12
- package/ci/build-package-requirements.ps1 +0 -1
- package/ci/build-package.ps1 +0 -14
- package/ci/build-project.ps1 +0 -16
- package/ci/fetch-assets.ps1 +0 -1
- package/ci/generate-types.ps1 +0 -8
- package/ci/get-next-package-version.ps1 +0 -10
- package/ci/install-package.ps1 +0 -8
- package/ci/options.json +0 -74
- package/ci/package-update-required.ps1 +0 -1
- package/ci/publish-package.ps1 +0 -10
- package/ci/run-integration-tests.ps1 +0 -22
- package/ci/run-performance-tests.ps1 +0 -8
- package/ci/run-unit-tests.ps1 +0 -8
- package/ci/setup-environment.ps1 +0 -13
- package/ci/update-packages.ps1 +0 -10
package/README.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# 51Degrees Geo-Location Engines
|
|
2
2
|
|
|
3
|
-
 **Pipeline API**
|
|
4
4
|
|
|
5
|
-
[Developer Documentation](https://51degrees.com/location-node/4.2/index.html?utm_source=github&utm_medium=
|
|
5
|
+
[Developer Documentation](https://51degrees.com/location-node/4.2/index.html?utm_source=github&utm_medium=readme&utm_campaign=51degrees-node&utm_content=readme.md&utm_term=51degrees-geo-location-engines "developer documentation")
|
|
6
6
|
|
|
7
7
|
## Introduction
|
|
8
8
|
|
|
@@ -56,5 +56,5 @@ jest
|
|
|
56
56
|
|
|
57
57
|
For complete documentation on the Pipeline API and associated engines, see the [51Degrees documentation site][Documentation].
|
|
58
58
|
|
|
59
|
-
[Documentation]: https://51degrees.com/documentation/index.html
|
|
59
|
+
[Documentation]: https://51degrees.com/documentation/index.html?utm_source=github&utm_medium=readme&utm_campaign=51degrees-node&utm_content=readme.md&utm_term=project-documentation
|
|
60
60
|
[npm]: https://www.npmjs.com/package/fiftyone.geolocation
|
package/docs/Doxyfile
CHANGED
|
@@ -51,7 +51,7 @@ PROJECT_BRIEF = "51Degrees Geo-Location for Node.js"
|
|
|
51
51
|
# pixels and the maximum width should not exceed 200 pixels. Doxygen will copy
|
|
52
52
|
# the logo to the output directory.
|
|
53
53
|
|
|
54
|
-
PROJECT_LOGO =
|
|
54
|
+
PROJECT_LOGO = ../../../documentation/docs/images/logo-51Degrees-Docs.png
|
|
55
55
|
|
|
56
56
|
# The PROJECT_URL tag is used to specify the URL which is linked by the
|
|
57
57
|
# PROJECT_LOGO.
|
|
@@ -63,7 +63,7 @@ PROJECT_URL = /documentation/4.5/index.html
|
|
|
63
63
|
# entered, it will be relative to the location where doxygen was started. If
|
|
64
64
|
# left blank the current directory will be used.
|
|
65
65
|
|
|
66
|
-
OUTPUT_DIRECTORY =
|
|
66
|
+
OUTPUT_DIRECTORY = .
|
|
67
67
|
|
|
68
68
|
# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
|
|
69
69
|
# directories (in 2 levels) under the output directory of each output format and
|
|
@@ -163,7 +163,7 @@ INLINE_INHERITED_MEMB = NO
|
|
|
163
163
|
# shortest path that makes the file name unique will be used
|
|
164
164
|
# The default value is: YES.
|
|
165
165
|
|
|
166
|
-
FULL_PATH_NAMES =
|
|
166
|
+
FULL_PATH_NAMES = NO
|
|
167
167
|
|
|
168
168
|
# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path.
|
|
169
169
|
# Stripping is only done if one of the specified strings matches the left-hand
|
|
@@ -877,8 +877,7 @@ EXCLUDE_SYMLINKS = NO
|
|
|
877
877
|
|
|
878
878
|
EXCLUDE_PATTERNS = */node_modules/* \
|
|
879
879
|
*/docs/* \
|
|
880
|
-
*/tests/*
|
|
881
|
-
*/device-detection-cxx/*
|
|
880
|
+
*/tests/*
|
|
882
881
|
|
|
883
882
|
# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
|
|
884
883
|
# (namespaces, classes, functions, etc.) that should be excluded from the
|
|
@@ -896,7 +895,7 @@ EXCLUDE_SYMBOLS =
|
|
|
896
895
|
# command).
|
|
897
896
|
|
|
898
897
|
EXAMPLE_PATH = ../examples \
|
|
899
|
-
|
|
898
|
+
../../../../src/snippets
|
|
900
899
|
|
|
901
900
|
# If the value of the EXAMPLE_PATH tag contains directories, you can use the
|
|
902
901
|
# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and
|
|
@@ -916,7 +915,7 @@ EXAMPLE_RECURSIVE = YES
|
|
|
916
915
|
# that contain images that are to be included in the documentation (see the
|
|
917
916
|
# \image command).
|
|
918
917
|
|
|
919
|
-
IMAGE_PATH =
|
|
918
|
+
IMAGE_PATH = ../../../documentation/docs/images
|
|
920
919
|
|
|
921
920
|
# The INPUT_FILTER tag can be used to specify a program that doxygen should
|
|
922
921
|
# invoke to filter for each input file. Doxygen will invoke the filter program
|
|
@@ -1128,7 +1127,7 @@ HTML_FILE_EXTENSION = .html
|
|
|
1128
1127
|
# of the possible markers and block names see the documentation.
|
|
1129
1128
|
# This tag requires that the tag GENERATE_HTML is set to YES.
|
|
1130
1129
|
|
|
1131
|
-
HTML_HEADER =
|
|
1130
|
+
HTML_HEADER = ../../../documentation/docs/header.html
|
|
1132
1131
|
|
|
1133
1132
|
# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each
|
|
1134
1133
|
# generated HTML page. If the tag is left blank doxygen will generate a standard
|
|
@@ -1138,7 +1137,7 @@ HTML_HEADER = ../../documentation/docs/header.html
|
|
|
1138
1137
|
# that doxygen normally uses.
|
|
1139
1138
|
# This tag requires that the tag GENERATE_HTML is set to YES.
|
|
1140
1139
|
|
|
1141
|
-
HTML_FOOTER =
|
|
1140
|
+
HTML_FOOTER = ../../../documentation/docs/footer.html
|
|
1142
1141
|
|
|
1143
1142
|
# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style
|
|
1144
1143
|
# sheet that is used by each HTML page. It can be used to fine-tune the look of
|
|
@@ -1150,7 +1149,7 @@ HTML_FOOTER = ../../documentation/docs/footer.html
|
|
|
1150
1149
|
# obsolete.
|
|
1151
1150
|
# This tag requires that the tag GENERATE_HTML is set to YES.
|
|
1152
1151
|
|
|
1153
|
-
HTML_STYLESHEET =
|
|
1152
|
+
HTML_STYLESHEET = ../../../documentation/docs/docs-main.min.css
|
|
1154
1153
|
|
|
1155
1154
|
# The HTML_EXTRA_STYLESHEET tag can be used to specify additional user-defined
|
|
1156
1155
|
# cascading style sheets that are included after the standard style sheets
|
|
@@ -1173,14 +1172,14 @@ HTML_EXTRA_STYLESHEET =
|
|
|
1173
1172
|
# files will be copied as-is; there are no commands or markers available.
|
|
1174
1173
|
# This tag requires that the tag GENERATE_HTML is set to YES.
|
|
1175
1174
|
|
|
1176
|
-
HTML_EXTRA_FILES =
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1175
|
+
HTML_EXTRA_FILES = ../../../documentation/docs/images/icon-arrow-left-black.svg \
|
|
1176
|
+
../../../documentation/docs/images/icon-arrow-right-black.svg \
|
|
1177
|
+
../../../documentation/docs/images/icon-arrow-solid-right-mute.svg \
|
|
1178
|
+
../../../documentation/docs/images/icon-arrow-solid-right-orange.svg \
|
|
1179
|
+
../../../documentation/docs/images/icon-search.svg \
|
|
1180
|
+
../../../documentation/docs/examplegrabber.js \
|
|
1181
|
+
../../../documentation/docs/testedversionsgrabber.js \
|
|
1182
|
+
../../../documentation/docs/search51.js
|
|
1184
1183
|
|
|
1185
1184
|
# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen
|
|
1186
1185
|
# will adjust the colors in the style sheet and background images according to
|
|
@@ -1468,6 +1467,7 @@ DISABLE_INDEX = YES
|
|
|
1468
1467
|
# This tag requires that the tag GENERATE_HTML is set to YES.
|
|
1469
1468
|
|
|
1470
1469
|
GENERATE_TREEVIEW = YES
|
|
1470
|
+
HTML_INDEX_NOINDEX = YES
|
|
1471
1471
|
|
|
1472
1472
|
# The HIDE_TREEVIEW_ROOT tag is used to remove the root node from the tree view.
|
|
1473
1473
|
# When not hidden, the tree root will be PROJECT_NAME. If the tree root is set
|
package/examples/51d.json
CHANGED
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
|
|
26
26
|
Example of using the 51Degrees geo-location Cloud alongside 51Degrees device detection to determine the country and device for a given longitude, latitude and User-Agent.
|
|
27
27
|
|
|
28
|
-
This example is available in full on [GitHub](https://github.com/51Degrees/
|
|
28
|
+
This example is available in full on [GitHub](https://github.com/51Degrees/51degrees-node/blob/main/location/examples/combiningServices.js).
|
|
29
29
|
|
|
30
30
|
To run this example, you will need to create a **resource key**.
|
|
31
31
|
The resource key is used as short-hand to store the particular set of
|
|
@@ -35,7 +35,7 @@ that entitle you to increased request limits and/or paid-for properties.
|
|
|
35
35
|
You will also need to install the fiftyone.devicedetection package with
|
|
36
36
|
`npm install fiftyone.devicedetection`.
|
|
37
37
|
|
|
38
|
-
You can create a resource key using the 51Degrees [Configurator](https://configure.51degrees.com).
|
|
38
|
+
You can create a resource key using the 51Degrees [Configurator](https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-combiningservices.js&utm_term=top).
|
|
39
39
|
|
|
40
40
|
*/
|
|
41
41
|
|
|
@@ -59,7 +59,7 @@ try {
|
|
|
59
59
|
console.log(e);
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
|
-
// You need to create a resource key at https://configure.51degrees.com and
|
|
62
|
+
// You need to create a resource key at https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-combiningservices.js&utm_term=top-2 and
|
|
63
63
|
// paste it into the code, replacing !!YOUR_RESOURCE_KEY!!.
|
|
64
64
|
// Make sure to include the isMobile and country properties as they
|
|
65
65
|
// are used by this example.
|
|
@@ -70,7 +70,7 @@ if (typeof localResourceKey === 'undefined' ||
|
|
|
70
70
|
|
|
71
71
|
if (localResourceKey.substr(0, 2) === '!!') {
|
|
72
72
|
console.log('You need to create a resource key at ' +
|
|
73
|
-
'https://configure.51degrees.com and paste it into the code, ' +
|
|
73
|
+
'https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-combiningservices.js&utm_term=resource-key-required and paste it into the code, ' +
|
|
74
74
|
'replacing !!YOUR_RESOURCE_KEY!!.');
|
|
75
75
|
console.log('Make sure to include the ismobile property ' +
|
|
76
76
|
'as it is used by this example.');
|
|
@@ -27,7 +27,7 @@ This example shows how to configure a pipeline with 51Degrees location
|
|
|
27
27
|
provider from a configuration file using the pipelineBuilder's
|
|
28
28
|
buildFromConfigurationFile method.
|
|
29
29
|
|
|
30
|
-
This example is available in full on [GitHub](https://github.com/51Degrees/
|
|
30
|
+
This example is available in full on [GitHub](https://github.com/51Degrees/51degrees-node/blob/main/location/examples/configureFromFile.js).
|
|
31
31
|
|
|
32
32
|
To run this example, you will need to create a **resource key**.
|
|
33
33
|
The resource key is used as short-hand to store the particular set of
|
|
@@ -35,7 +35,7 @@ properties you are interested in as well as any associated license keys
|
|
|
35
35
|
that entitle you to increased request limits and/or paid-for properties.
|
|
36
36
|
|
|
37
37
|
You can create a resource key using the 51Degrees
|
|
38
|
-
[Configurator](https://configure.51degrees.com).
|
|
38
|
+
[Configurator](https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-configurefromfile.js&utm_term=top).
|
|
39
39
|
|
|
40
40
|
Make sure to include the Country property, as it is required to run this
|
|
41
41
|
example.
|
|
@@ -92,7 +92,7 @@ if (config.PipelineOptions.Elements[0].elementParameters.resourceKey
|
|
|
92
92
|
// rest of the example.
|
|
93
93
|
resourceKeySet = false;
|
|
94
94
|
console.log('You need to create a resource key at ' +
|
|
95
|
-
'https://configure.51degrees.com and paste it into the 51d.json ' +
|
|
95
|
+
'https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-configurefromfile.js&utm_term=resource-key-required and paste it into the 51d.json ' +
|
|
96
96
|
'config file, replacing !!YOUR_RESOURCE_KEY!!.');
|
|
97
97
|
}
|
|
98
98
|
|
|
@@ -25,14 +25,14 @@
|
|
|
25
25
|
|
|
26
26
|
Getting started example of using the 51Degrees geo-location Cloud to determine the country for a given longitude and latitude.
|
|
27
27
|
|
|
28
|
-
This example is available in full on [GitHub](https://github.com/51Degrees/
|
|
28
|
+
This example is available in full on [GitHub](https://github.com/51Degrees/51degrees-node/blob/main/location/examples/gettingStarted.js).
|
|
29
29
|
|
|
30
30
|
To run this example, you will need to create a **resource key**.
|
|
31
31
|
The resource key is used as short-hand to store the particular set of
|
|
32
32
|
properties you are interested in as well as any associated license keys
|
|
33
33
|
that entitle you to increased request limits and/or paid-for properties.
|
|
34
34
|
|
|
35
|
-
You can create a resource key using the 51Degrees [Configurator](https://configure.51degrees.com).
|
|
35
|
+
You can create a resource key using the 51Degrees [Configurator](https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-gettingstarted.js&utm_term=top).
|
|
36
36
|
|
|
37
37
|
Firstly require the fiftyone.geolocation modules which contain all of the pipeline specific classes we will be using in this example.
|
|
38
38
|
|
|
@@ -108,7 +108,7 @@ try {
|
|
|
108
108
|
console.log(e);
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
-
// You need to create a resource key at https://configure.51degrees.com and
|
|
111
|
+
// You need to create a resource key at https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-gettingstarted.js&utm_term=top-2 and
|
|
112
112
|
// paste it into the code, replacing !!YOUR_RESOURCE_KEY!!.
|
|
113
113
|
if (typeof localResourceKey === 'undefined' ||
|
|
114
114
|
localResourceKey.substr(0, 2) === '!!') {
|
|
@@ -117,7 +117,7 @@ if (typeof localResourceKey === 'undefined' ||
|
|
|
117
117
|
|
|
118
118
|
if (localResourceKey.substr(0, 2) === '!!') {
|
|
119
119
|
console.log('You need to create a resource key at ' +
|
|
120
|
-
'https://configure.51degrees.com and paste it into the code, ' +
|
|
120
|
+
'https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-gettingstarted.js&utm_term=resource-key-required and paste it into the code, ' +
|
|
121
121
|
'replacing !!YOUR_RESOURCE_KEY!!.');
|
|
122
122
|
} else {
|
|
123
123
|
const pipeline = new FiftyOneDegreesGeoLocation.GeoLocationPipelineBuilder({
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
|
|
26
26
|
@include{doc} example-web-integration-location.txt
|
|
27
27
|
|
|
28
|
-
This example is available in full on [GitHub](https://github.com/51Degrees/
|
|
28
|
+
This example is available in full on [GitHub](https://github.com/51Degrees/51degrees-node/blob/main/location/examples/webIntegration.js).
|
|
29
29
|
|
|
30
30
|
@include{doc} example-require-resourcekey.txt
|
|
31
31
|
*/
|
|
@@ -33,7 +33,7 @@ This example is available in full on [GitHub](https://github.com/51Degrees/locat
|
|
|
33
33
|
const FiftyOneDegreesLocation = require((process.env.directory || __dirname) + '/../');
|
|
34
34
|
|
|
35
35
|
// Obtain a resource key with the properties required to test this
|
|
36
|
-
// example for free: https://configure.51degrees.com/v399y42f
|
|
36
|
+
// example for free: https://configure.51degrees.com/v399y42f?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-webintegration.js&utm_term=top
|
|
37
37
|
// The properties used in this example are:
|
|
38
38
|
// Country, State, County, Town, JavaScript
|
|
39
39
|
const myResourceKey = process.env.RESOURCE_KEY || '!!YOUR_RESOURCE_KEY!!';
|
|
@@ -44,11 +44,11 @@ let server;
|
|
|
44
44
|
|
|
45
45
|
if (myResourceKey.substring(0, 2) === '!!') {
|
|
46
46
|
console.log('You need to create a resource key at ' +
|
|
47
|
-
'https://configure.51degrees.com and paste it into the code, ' +
|
|
47
|
+
'https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-webintegration.js&utm_term=resource-key-required and paste it into the code, ' +
|
|
48
48
|
'replacing !!YOUR_RESOURCE_KEY!!');
|
|
49
49
|
} else {
|
|
50
50
|
// Create a new pipeline and set the config.
|
|
51
|
-
// You need to create a resource key at https://configure.51degrees.com
|
|
51
|
+
// You need to create a resource key at https://configure.51degrees.com?utm_source=code&utm_medium=example&utm_campaign=51degrees-node&utm_content=examples-webintegration.js&utm_term=top
|
|
52
52
|
// and paste it into the code.
|
|
53
53
|
// The JavaScriptBuilderSettings allow you to provide an endpoint
|
|
54
54
|
// which will be requested by the client side JavaScript.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fiftyone.geolocation",
|
|
3
|
-
"version": "4.5.
|
|
3
|
+
"version": "4.5.99",
|
|
4
4
|
"description": "Perform reverse geocoding using longitude and latitude to populate postal addresses",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"51Degrees",
|
|
@@ -23,13 +23,14 @@
|
|
|
23
23
|
"author": "51Degrees Engineering <engineering@51degrees.com>",
|
|
24
24
|
"repository": {
|
|
25
25
|
"type": "git",
|
|
26
|
-
"url": "https://github.com/51Degrees/
|
|
26
|
+
"url": "https://github.com/51Degrees/51degrees-node",
|
|
27
|
+
"directory": "location"
|
|
27
28
|
},
|
|
28
29
|
"dependencies": {
|
|
29
|
-
"fiftyone.pipeline.cloudrequestengine": "4.
|
|
30
|
-
"fiftyone.pipeline.core": "4.
|
|
31
|
-
"fiftyone.pipeline.engines": "4.
|
|
32
|
-
"fiftyone.pipeline.engines.fiftyone": "4.
|
|
30
|
+
"fiftyone.pipeline.cloudrequestengine": "^4.5.0",
|
|
31
|
+
"fiftyone.pipeline.core": "^4.5.0",
|
|
32
|
+
"fiftyone.pipeline.engines": "^4.5.0",
|
|
33
|
+
"fiftyone.pipeline.engines.fiftyone": "^4.5.0"
|
|
33
34
|
},
|
|
34
35
|
"devDependencies": {
|
|
35
36
|
"@types/node": "^15.14.9",
|
|
@@ -48,7 +49,7 @@
|
|
|
48
49
|
},
|
|
49
50
|
"license": "EUPL-1.2",
|
|
50
51
|
"bugs": {
|
|
51
|
-
"url": "https://github.com/51Degrees/
|
|
52
|
+
"url": "https://github.com/51Degrees/51degrees-node/issues"
|
|
52
53
|
},
|
|
53
54
|
"jest-junit": {
|
|
54
55
|
"outputName": "test_results.xml"
|
package/tsconfig.json
CHANGED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
name: Monthly Copyright Update
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
inputs:
|
|
6
|
-
dryrun:
|
|
7
|
-
default: false
|
|
8
|
-
type: boolean
|
|
9
|
-
description: Dry Run
|
|
10
|
-
schedule:
|
|
11
|
-
- cron: '0 0 1 * *'
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
Monthly_Copyright_Update:
|
|
15
|
-
uses: 51Degrees/common-ci/.github/workflows/monthly-copyright-update.yml@main
|
|
16
|
-
with:
|
|
17
|
-
repo-name: ${{ github.event.repository.name }}
|
|
18
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
19
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
20
|
-
secrets:
|
|
21
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
name: Nightly Pipeline
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
inputs:
|
|
6
|
-
dryrun:
|
|
7
|
-
type: boolean
|
|
8
|
-
default: false
|
|
9
|
-
schedule:
|
|
10
|
-
- cron: '0 3 * * *'
|
|
11
|
-
|
|
12
|
-
jobs:
|
|
13
|
-
PackageUpdate:
|
|
14
|
-
# This is intentionally disabled to prevent npm updates, otherwise it is
|
|
15
|
-
# causing an endless dependency update loop for fiftyone.* packages in this
|
|
16
|
-
# repository.
|
|
17
|
-
# TODO: Don't forget to add this job to PullRequests' needs when enabling back.
|
|
18
|
-
if: false
|
|
19
|
-
name: Nightly Package Update
|
|
20
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-package-update.yml@main
|
|
21
|
-
with:
|
|
22
|
-
repo-name: ${{ github.event.repository.name }}
|
|
23
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
24
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
25
|
-
secrets:
|
|
26
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
27
|
-
|
|
28
|
-
PullRequests:
|
|
29
|
-
if: ${{ !cancelled() }}
|
|
30
|
-
# needs: PackageUpdate
|
|
31
|
-
name: Nightly Pull Requests
|
|
32
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-pull-requests.yml@main
|
|
33
|
-
with:
|
|
34
|
-
repo-name: ${{ github.event.repository.name }}
|
|
35
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
36
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
37
|
-
secrets:
|
|
38
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
39
|
-
TestResourceKey: ${{ secrets.SUPER_RESOURCE_KEY}}
|
|
40
|
-
DeviceDetection: ${{ secrets.DEVICE_DETECTION_KEY }}
|
|
41
|
-
|
|
42
|
-
Publish:
|
|
43
|
-
if: ${{ !cancelled() }}
|
|
44
|
-
needs: PullRequests
|
|
45
|
-
name: Nightly Publish
|
|
46
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-publish.yml@main
|
|
47
|
-
with:
|
|
48
|
-
repo-name: ${{ github.event.repository.name }}
|
|
49
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
50
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
51
|
-
secrets:
|
|
52
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
53
|
-
TestResourceKey: ${{ secrets.SUPER_RESOURCE_KEY}}
|
|
54
|
-
DeviceDetection: ${{ secrets.DEVICE_DETECTION_KEY }}
|
|
55
|
-
NPMAuthToken: ${{ secrets.NPM_AUTH_TOKEN}}
|
|
56
|
-
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
name: Package Update
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
inputs:
|
|
6
|
-
dryrun:
|
|
7
|
-
type: boolean
|
|
8
|
-
default: false
|
|
9
|
-
|
|
10
|
-
jobs:
|
|
11
|
-
PackageUpdate:
|
|
12
|
-
name: Package Update
|
|
13
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-package-update.yml@main
|
|
14
|
-
with:
|
|
15
|
-
repo-name: ${{ github.event.repository.name }}
|
|
16
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
17
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
18
|
-
secrets:
|
|
19
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
name: Publish
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
inputs:
|
|
6
|
-
dryrun:
|
|
7
|
-
type: boolean
|
|
8
|
-
default: false
|
|
9
|
-
|
|
10
|
-
jobs:
|
|
11
|
-
Publish:
|
|
12
|
-
name: Publish
|
|
13
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-publish.yml@main
|
|
14
|
-
with:
|
|
15
|
-
repo-name: ${{ github.event.repository.name }}
|
|
16
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
17
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
18
|
-
secrets:
|
|
19
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
20
|
-
TestResourceKey: ${{ secrets.SUPER_RESOURCE_KEY}}
|
|
21
|
-
DeviceDetection: ${{ secrets.DEVICE_DETECTION_KEY }}
|
|
22
|
-
NPMAuthToken: ${{ secrets.NPM_AUTH_TOKEN}}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
name: Pull Requests
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
inputs:
|
|
6
|
-
dryrun:
|
|
7
|
-
type: boolean
|
|
8
|
-
default: false
|
|
9
|
-
|
|
10
|
-
jobs:
|
|
11
|
-
PullRequests:
|
|
12
|
-
name: Pull Requests
|
|
13
|
-
uses: 51Degrees/common-ci/.github/workflows/nightly-pull-requests.yml@main
|
|
14
|
-
with:
|
|
15
|
-
repo-name: ${{ github.event.repository.name }}
|
|
16
|
-
org-name: ${{ github.event.repository.owner.login }}
|
|
17
|
-
dryrun: ${{ inputs.dryrun || false }}
|
|
18
|
-
secrets:
|
|
19
|
-
token: ${{ secrets.ACCESS_TOKEN }}
|
|
20
|
-
TestResourceKey: ${{ secrets.SUPER_RESOURCE_KEY}}
|
|
21
|
-
DeviceDetection: ${{ secrets.DEVICE_DETECTION_KEY }}
|
package/.gitmodules
DELETED
package/ci/README.md
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
# API Specific CI/CD Approach
|
|
2
|
-
This API complies with the `common-ci` approach.
|
|
3
|
-
|
|
4
|
-
The following secrets are required:
|
|
5
|
-
* `ACCESS_TOKEN` - GitHub [access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#about-personal-access-tokens) for cloning repos, creating PRs, etc.
|
|
6
|
-
* Example: `github_pat_l0ng_r4nd0m_s7r1ng`
|
|
7
|
-
* `SUPER_RESOURCE_KEY` - [resource key](https://51degrees.com/documentation/4.4/_info__resource_keys.html) for integration tests
|
|
8
|
-
* Example: `R4nd0m-S7r1ng`
|
|
9
|
-
* `DEVICE_DETECTION_KEY` - [license key](https://51degrees.com/pricing) for downloading assets (TAC hashes file and TAC CSV data file)
|
|
10
|
-
* Example: `V3RYL0NGR4ND0M57R1NG`
|
|
11
|
-
* `NPM_AUTH_TOKEN` - [NPM token](https://docs.npmjs.com/creating-and-viewing-access-tokens) for publishing packages
|
|
12
|
-
* Example: `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`
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Write-Output "No requirements needed"
|
package/ci/build-package.ps1
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
param (
|
|
2
|
-
[Parameter(Mandatory=$true)]
|
|
3
|
-
[string]$RepoName,
|
|
4
|
-
[Parameter(Mandatory=$true)]
|
|
5
|
-
[string]$Version
|
|
6
|
-
)
|
|
7
|
-
|
|
8
|
-
$packages = "."
|
|
9
|
-
|
|
10
|
-
$noRemote = "."
|
|
11
|
-
|
|
12
|
-
./node/build-package-npm.ps1 -RepoName $RepoName -Packages $packages -NoRemote $noRemote -Version $Version
|
|
13
|
-
|
|
14
|
-
exit $LASTEXITCODE
|
package/ci/build-project.ps1
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
param (
|
|
2
|
-
[Parameter(Mandatory=$true)]
|
|
3
|
-
[string]$RepoName
|
|
4
|
-
)
|
|
5
|
-
|
|
6
|
-
$packages = ".";
|
|
7
|
-
|
|
8
|
-
Push-Location $RepoName
|
|
9
|
-
|
|
10
|
-
Remove-Item -Path ./package-lock.json -Force
|
|
11
|
-
|
|
12
|
-
Pop-Location
|
|
13
|
-
|
|
14
|
-
./node/build-project.ps1 -RepoName $RepoName -Packages $packages
|
|
15
|
-
|
|
16
|
-
exit $LASTEXITCODE
|
package/ci/fetch-assets.ps1
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Write-Output "No assets needed"
|
package/ci/generate-types.ps1
DELETED
package/ci/install-package.ps1
DELETED
package/ci/options.json
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
[
|
|
2
|
-
{
|
|
3
|
-
"Name": "Ubuntu_Node_20",
|
|
4
|
-
"Image": "ubuntu-latest",
|
|
5
|
-
"Language": "node",
|
|
6
|
-
"LanguageVersion": "20",
|
|
7
|
-
"RunPerformance": true,
|
|
8
|
-
"PackageRequirement": true
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
"Name": "Windows_Node_20",
|
|
12
|
-
"Image": "windows-latest",
|
|
13
|
-
"Language": "node",
|
|
14
|
-
"LanguageVersion": "20",
|
|
15
|
-
"RunPerformance": true,
|
|
16
|
-
"PackageRequirement": true
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
"Name": "macOS_Node_20",
|
|
20
|
-
"Image": "macos-latest",
|
|
21
|
-
"Language": "node",
|
|
22
|
-
"LanguageVersion": "20",
|
|
23
|
-
"RunPerformance": true,
|
|
24
|
-
"PackageRequirement": true
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
"Name": "Ubuntu_Node_22",
|
|
28
|
-
"Image": "ubuntu-latest",
|
|
29
|
-
"Language": "node",
|
|
30
|
-
"LanguageVersion": "22.5.1",
|
|
31
|
-
"RunPerformance": true,
|
|
32
|
-
"PackageRequirement": true
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
"Name": "Windows_Node_22",
|
|
36
|
-
"Image": "windows-latest",
|
|
37
|
-
"Language": "node",
|
|
38
|
-
"LanguageVersion": "22.5.1",
|
|
39
|
-
"RunPerformance": true,
|
|
40
|
-
"PackageRequirement": true
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
"Name": "macOS_Node_22",
|
|
44
|
-
"Image": "macos-latest",
|
|
45
|
-
"Language": "node",
|
|
46
|
-
"LanguageVersion": "22.5.1",
|
|
47
|
-
"RunPerformance": true,
|
|
48
|
-
"PackageRequirement": true
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
"Name": "Ubuntu_Node_24",
|
|
52
|
-
"Image": "ubuntu-latest",
|
|
53
|
-
"Language": "node",
|
|
54
|
-
"LanguageVersion": "24",
|
|
55
|
-
"RunPerformance": true,
|
|
56
|
-
"PackageRequirement": true
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
"Name": "Windows_Node_24",
|
|
60
|
-
"Image": "windows-latest",
|
|
61
|
-
"Language": "node",
|
|
62
|
-
"LanguageVersion": "24",
|
|
63
|
-
"RunPerformance": true,
|
|
64
|
-
"PackageRequirement": true
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
"Name": "macOS_Node_24",
|
|
68
|
-
"Image": "macos-latest",
|
|
69
|
-
"Language": "node",
|
|
70
|
-
"LanguageVersion": "24",
|
|
71
|
-
"RunPerformance": true,
|
|
72
|
-
"PackageRequirement": true
|
|
73
|
-
}
|
|
74
|
-
]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Write-Output "Updates needed"
|
package/ci/publish-package.ps1
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
param (
|
|
2
|
-
[Parameter(Mandatory=$true)]
|
|
3
|
-
[string]$RepoName,
|
|
4
|
-
[Parameter(Mandatory=$true)]
|
|
5
|
-
$Keys
|
|
6
|
-
)
|
|
7
|
-
|
|
8
|
-
Push-Location $RepoName
|
|
9
|
-
|
|
10
|
-
try
|
|
11
|
-
{
|
|
12
|
-
Write-Output "Running integration tests"
|
|
13
|
-
$env:RESOURCE_KEY = $Keys.TestResourceKey
|
|
14
|
-
$env:JEST_JUNIT_OUTPUT_DIR = 'test-results/integration'
|
|
15
|
-
npm run test
|
|
16
|
-
} finally {
|
|
17
|
-
Pop-Location
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
if ($LASTEXITCODE -ne 0) {
|
|
21
|
-
exit $LASTEXITCODE
|
|
22
|
-
}
|
package/ci/run-unit-tests.ps1
DELETED
package/ci/setup-environment.ps1
DELETED