diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..da912cf --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,9 @@ +{ + "workbench.colorCustomizations": { + "activityBar.background": "#372D0D", + "titleBar.activeBackground": "#4D3F12", + "titleBar.activeForeground": "#FDFBF5" + }, + "prettier.singleQuote": true, + "prettier.tabWidth": 2 +} \ No newline at end of file diff --git a/README.md b/README.md index 79aeb82..8856baa 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,8 @@ The script will take the following from the `package.json` in the root of your p The `"pluginFiles"` list is used to specify all the files and directories that should be included in the plugin package. Directories are specified by adding a trailing slash `/`. It can be left out and will default to `["META-INF/", "resources/", "plugin.xml"]`. +Additionally, the environment variable `BUILD_TIMESTAMP` can be used to set a custom timestamp in the created zip file name. Without this, a timestamp will be created from the current time. + ## Run Make sure that your current working directory is the root of your web plugin. diff --git a/index.js b/index.js index d69495a..6897bc0 100644 --- a/index.js +++ b/index.js @@ -10,7 +10,7 @@ const packageJson = require(path.resolve('./package.json')); const placeholders = { pluginId: packageJson.packJazzWebPlugin.pluginId, pluginName: packageJson.name, - pluginVersion: `${packageJson.version}_${getFormattedDate(new Date())}`, + pluginVersion: `${packageJson.version}_${process.env.BUILD_TIMESTAMP || getFormattedDate(new Date())}`, pluginDescription: packageJson.description, pluginAuthor: packageJson.author, pluginLicense: packageJson.license, diff --git a/package.json b/package.json index 6f62465..a600050 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@jazz-community-org/pack-jazz-web-plugin", - "version": "2.0.0", + "version": "2.0.1", "description": "Script for packaging a JavaScript plugin for the IBM Jazz Platform", "bin": "index.js", "repository": {