win-get-updates 0.0.1 → 0.0.3

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.
@@ -1,26 +1,25 @@
1
1
  # See https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/configuration-options-for-dependency-updates
2
2
  version: 2
3
3
  updates:
4
- - package-ecosystem: "npm"
5
- directory: "/"
4
+ - package-ecosystem: 'npm'
5
+ directory: '/'
6
6
  schedule:
7
- interval: "monthly"
8
- open-pull-requests-limit: 5
7
+ interval: 'monthly'
8
+ timezone: 'Europe/Berlin'
9
+ open-pull-requests-limit: 10
9
10
  commit-message:
10
- prefix: "deps"
11
+ prefix: 'deps'
11
12
  labels:
12
- - "dependencies"
13
- ignore:
14
- - dependency-name: "eslint"
15
- update-types: ["version-update:semver-major"]
16
- - dependency-name: "prettier"
17
- update-types: ["version-update:semver-major"]
18
- - package-ecosystem: "github-actions"
19
- directory: "/"
13
+ - 'dependencies'
14
+ target-branch: 'develop'
15
+ - package-ecosystem: 'github-actions'
16
+ directory: '/'
20
17
  schedule:
21
- interval: "monthly"
22
- open-pull-requests-limit: 5
18
+ interval: 'monthly'
19
+ timezone: 'Europe/Berlin'
20
+ open-pull-requests-limit: 10
23
21
  commit-message:
24
- prefix: "ci"
22
+ prefix: 'ci-actions'
25
23
  labels:
26
- - "ci"
24
+ - 'ci-actions'
25
+ target-branch: 'develop'
@@ -1,20 +1,24 @@
1
1
  name: Lint and Format
2
+ run-name: Lint and Format ${{ github.run_number }}
3
+
2
4
  on:
3
5
  push:
4
- branches: ['**']
6
+ branches:
7
+ - develop
5
8
  pull_request:
6
- branches: ['**']
9
+
7
10
  permissions:
8
11
  contents: read
12
+
9
13
  jobs:
10
14
  lint-and-format:
11
15
  name: Lint and Format
12
16
  runs-on: ubuntu-latest
13
17
  steps:
14
18
  - name: Checkout code
15
- uses: actions/checkout@v4
19
+ uses: actions/checkout@v6
16
20
  - name: Set up Node.js
17
- uses: actions/setup-node@v4
21
+ uses: actions/setup-node@v6
18
22
  with:
19
23
  node-version: 'lts/*'
20
24
  - name: Install dependencies
@@ -0,0 +1,22 @@
1
+ name: Publish
2
+ run-name: Release run ${{ github.run_number }}
3
+
4
+ on:
5
+ workflow_dispatch:
6
+
7
+ permissions:
8
+ id-token: write # Required for npm<->GitHub OIDC
9
+ contents: read
10
+
11
+ jobs:
12
+ publish:
13
+ runs-on: ubuntu-latest
14
+ steps:
15
+ - uses: actions/checkout@v6
16
+
17
+ - uses: actions/setup-node@v6
18
+ with:
19
+ node-version: 'lts/*'
20
+ registry-url: 'https://registry.npmjs.org'
21
+ - run: npm ci
22
+ - run: npm publish
package/README.md CHANGED
@@ -6,8 +6,22 @@ Third party CLI frontend for [winget](https://en.wikipedia.org/wiki/Windows_Pack
6
6
 
7
7
  Windows with [winget](https://en.wikipedia.org/wiki/Windows_Package_Manager) installed. Supposed to run on cmd.exe.
8
8
 
9
+ ## Install
10
+
11
+ ```
12
+ npm install -g win-get-updates
13
+ ```
14
+
9
15
  ## Run
10
16
 
17
+ ### Global
18
+
19
+ ```
20
+ wgu
21
+ ```
22
+
23
+ ### Local development
24
+
11
25
  ```
12
26
  node src\cli.js
13
27
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "win-get-updates",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "description": "Third party CLI frontend for winget update runs.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -17,7 +17,7 @@
17
17
  },
18
18
  "scripts": {
19
19
  "start": "node src/cli.js",
20
- "version:gen": "node -p \"'const WGU_VERSION = \"' + require('./package.json').version + '\";\\nexport default WGU_VERSION;'\" > src/lib/version.js",
20
+ "version:gen": "node -p \"'const WGU_VERSION = \\'' + require('./package.json').version + '\\';\\nexport default WGU_VERSION;'\" > src/lib/version.js",
21
21
  "lint": "eslint .",
22
22
  "lint:fix": "eslint . --fix",
23
23
  "format": "prettier --check .",
package/src/lib/menu.js CHANGED
@@ -18,8 +18,10 @@ export async function interactiveSelect(items) {
18
18
  let activeLine = 0;
19
19
 
20
20
  // Display initial menu
21
- for (const item of items) {
22
- console.log(`[ ] ${item}`);
21
+ for (let i = 0; i < items.length; i++) {
22
+ const item = items[i];
23
+ console.log(`[x] ${item}`);
24
+ selectedLines.set(i, true);
23
25
  }
24
26
  console.log('');
25
27
  console.log("Use Up/Down arrows to navigate, Space to toggle selection, 'y' to confirm, 'q' to quit.");
@@ -1,3 +1,2 @@
1
- const WGU_VERSION = '0.0.1';
2
-
1
+ const WGU_VERSION = '0.0.3';
3
2
  export default WGU_VERSION;