Skip to content

Commit a10ec7a

Browse files
committed
Squashed commit
1 parent 6a32aa5 commit a10ec7a

23 files changed

+180
-80
lines changed

.github/workflows/build_and_test.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
push:
88
branches:
99
- main
10+
11+
permissions:
12+
contents: read
13+
1014
jobs:
1115
build-and-test:
1216
runs-on: ${{ matrix.os }}

.github/workflows/releases.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ on:
1010
types:
1111
- released
1212

13+
permissions:
14+
contents: read
15+
1316
jobs:
1417
notify:
1518
# This job can run on the latest Ubuntu

.github/workflows/semantic-pr.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ on:
77
- edited
88
- synchronize
99

10+
permissions:
11+
pull-requests: read
12+
1013
jobs:
1114
main:
1215
name: Validate semantic PR title

.github/workflows/spell-check-lint.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ on:
44
types: [opened, synchronize, edited]
55
branches:
66
- main
7+
8+
permissions:
9+
contents: read
10+
711
jobs:
812
spellcheck-request-title:
913
runs-on: ubuntu-latest

package-lock.json

Lines changed: 58 additions & 60 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"express": "^4.21.1",
3939
"fs-extra": "^10.1.0",
4040
"inquirer": "^8.2.7",
41-
"js-yaml": "^3.13.1",
41+
"js-yaml": "^4.1.1",
4242
"keychain": "^1.4.0",
4343
"keytar": "^7.9.0",
4444
"lodash": "^4.17.13",

src/box-command.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ function formatObject(obj) {
256256
let outputData = formatObjectKeys(obj);
257257

258258
// Other objects are formatted as YAML for human-readable output
259-
let yamlString = yaml.safeDump(outputData, {
259+
let yamlString = yaml.dump(outputData, {
260260
indent: 4,
261261
noRefs: true,
262262
});

test/fixtures/bulk/saveTest.txt

Lines changed: 89 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,89 @@
1-
foo
1+
[
2+
{
3+
"type": "collaboration",
4+
"id": "1234567890",
5+
"created_by": {
6+
"type": "user",
7+
"id": "9753108642",
8+
"name": "Inviting User",
9+
"login": "[email protected]"
10+
},
11+
"created_at": "2016-11-16T21:33:31-08:00",
12+
"modified_at": "2016-11-16T21:33:31-08:00",
13+
"expires_at": null,
14+
"status": "accepted",
15+
"accessible_by": {
16+
"type": "user",
17+
"id": "987654321",
18+
"name": "Steve Jobs",
19+
"login": "[email protected]"
20+
},
21+
"role": "previewer",
22+
"acknowledged_at": "2016-11-16T21:33:31-08:00",
23+
"item": {
24+
"type": "file",
25+
"id": "11111",
26+
"sequence_id": "0",
27+
"etag": "0",
28+
"name": "Collaborated File"
29+
}
30+
},
31+
{
32+
"type": "collaboration",
33+
"id": "1234567891",
34+
"created_by": {
35+
"type": "user",
36+
"id": "9753108642",
37+
"name": "Inviting User",
38+
"login": "[email protected]"
39+
},
40+
"created_at": "2016-11-16T21:33:31-08:00",
41+
"modified_at": "2016-11-16T21:33:31-08:00",
42+
"expires_at": null,
43+
"status": "accepted",
44+
"accessible_by": {
45+
"type": "user",
46+
"id": "987654322",
47+
"name": "Roger Federer",
48+
"login": "[email protected]"
49+
},
50+
"role": "previewer",
51+
"acknowledged_at": "2016-11-16T21:33:31-08:00",
52+
"item": {
53+
"type": "file",
54+
"id": "22222",
55+
"sequence_id": "0",
56+
"etag": "0",
57+
"name": "Collaborated File"
58+
}
59+
},
60+
{
61+
"type": "collaboration",
62+
"id": "1234567892",
63+
"created_by": {
64+
"type": "user",
65+
"id": "9753108642",
66+
"name": "Inviting User",
67+
"login": "[email protected]"
68+
},
69+
"created_at": "2016-11-16T21:33:31-08:00",
70+
"modified_at": "2016-11-16T21:33:31-08:00",
71+
"expires_at": null,
72+
"status": "accepted",
73+
"accessible_by": {
74+
"type": "user",
75+
"id": "987654323",
76+
"name": "Dominic Toretto",
77+
"login": "[email protected]"
78+
},
79+
"role": "previewer",
80+
"acknowledged_at": "2016-11-16T21:33:31-08:00",
81+
"item": {
82+
"type": "file",
83+
"id": "33333",
84+
"sequence_id": "0",
85+
"etag": "0",
86+
"name": "Collaborated File"
87+
}
88+
}
89+
]

test/fixtures/output/files_share_yaml.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
Type: file
22
ID: '1234567890'
33
Shared Link:
4-
URL: 'https://blosserdemoaccount.box.com/s/7mcmdlavtye5o5i0ue8xmtwh2sx5bv8p'
4+
URL: https://blosserdemoaccount.box.com/s/7mcmdlavtye5o5i0ue8xmtwh2sx5bv8p
55
Download URL: >-
66
https://blosserdemoaccount.box.com/shared/static/7mcmdlavtye5o5i0ue8xmtwh2sx5bv8p.png
7-
Vanity URL: 'https://app.box.com/v/my-custom-name-123'
7+
Vanity URL: https://app.box.com/v/my-custom-name-123
88
Effective Access: open
99
Is Password Enabled: true
1010
Unshared At: null

test/fixtures/output/files_upload_yaml.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Type: file
22
ID: '1234567890'
33
File Version:
44
Type: file_version
5-
ID: 098765432109
5+
ID: '098765432109'
66
SHA1: 0beec7b5ea3f0fdbc95d0dd47f3c5bc275da8a33
77
Sequence ID: '0'
88
ETag: '0'

0 commit comments

Comments
 (0)