Skip to content

Commit 34c78e9

Browse files
authored
meta: run Prettier on existing files (#4713)
1 parent a5f6248 commit 34c78e9

File tree

172 files changed

+3024
-1771
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

172 files changed

+3024
-1771
lines changed

.github/ISSUE_TEMPLATE/1-bug.yml

+10-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ body:
77
attributes:
88
label: Initial checklist
99
options:
10-
- label: I understand this is a bug report and questions should be posted in the [Community Forum](https://community.transloadit.com/)
10+
- label:
11+
I understand this is a bug report and questions should be posted in
12+
the [Community Forum](https://community.transloadit.com/)
1113
required: true
12-
- label: I searched [issues](https://github.com/transloadit/uppy/issues?q=is%3Aissue) and couldn’t find anything (or linked relevant results below)
14+
- label:
15+
I searched
16+
[issues](https://github.com/transloadit/uppy/issues?q=is%3Aissue)
17+
and couldn’t find anything (or linked relevant results below)
1318
required: true
1419
- type: input
1520
id: runnable-example
@@ -28,7 +33,9 @@ body:
2833
id: steps-to-reproduce
2934
attributes:
3035
label: Steps to reproduce
31-
description: How did this happen? Please provide a [minimal, reproducible example](https://stackoverflow.com/help/minimal-reproducible-example).
36+
description:
37+
How did this happen? Please provide a [minimal, reproducible
38+
example](https://stackoverflow.com/help/minimal-reproducible-example).
3239
validations:
3340
required: true
3441
- type: textarea

.github/ISSUE_TEMPLATE/2-feature.yml

+10-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ body:
77
attributes:
88
label: Initial checklist
99
options:
10-
- label: I understand this is a feature request and questions should be posted in the [Community Forum](https://community.transloadit.com/)
10+
- label:
11+
I understand this is a feature request and questions should be
12+
posted in the [Community Forum](https://community.transloadit.com/)
1113
required: true
12-
- label: I searched [issues](https://github.com/transloadit/uppy/issues?q=is%3Aissue) and couldn’t find anything (or linked relevant results below)
14+
- label:
15+
I searched
16+
[issues](https://github.com/transloadit/uppy/issues?q=is%3Aissue)
17+
and couldn’t find anything (or linked relevant results below)
1318
required: true
1419
- type: textarea
1520
id: problem
@@ -29,6 +34,8 @@ body:
2934
id: alternatives
3035
attributes:
3136
label: Alternatives
32-
description: What are the alternative solutions? Can this be solved in a different way?
37+
description:
38+
What are the alternative solutions? Can this be solved in a different
39+
way?
3340
validations:
3441
required: true

.github/stale.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ staleLabel: Stale
1111
# Comment to post when marking an issue as stale. Set to `false` to disable
1212
markComment: >
1313
This issue has been automatically marked as stale because it has not had
14-
recent activity. If the issue is still relevant, please upvote or leave a comment.
15-
Thank you for your contribution!
14+
recent activity. If the issue is still relevant, please upvote or leave a
15+
comment. Thank you for your contribution!
1616
# Comment to post when closing a stale issue. Set to `false` to disable
1717
closeComment: false

.github/workflows/bundlers.yml

+32-18
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ name: Test different bundlers with Uppy
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
pull_request:
77
# We want all branches so we configure types to be the GH default again
8-
types: [ opened, synchronize, reopened ]
8+
types: [opened, synchronize, reopened]
99
paths-ignore:
1010
- '**.md'
1111
- '**.d.ts'
@@ -27,7 +27,8 @@ jobs:
2727
uses: actions/checkout@v3
2828
- name: Get yarn cache directory path
2929
id: yarn-cache-dir-path
30-
run: echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
30+
run:
31+
echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
3132
- uses: actions/cache@v3
3233
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
3334
with:
@@ -40,7 +41,10 @@ jobs:
4041
with:
4142
node-version: lts/*
4243
- name: Install dependencies
43-
run: corepack yarn workspaces focus $(corepack yarn workspaces list --json | jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io") print $0 }')
44+
run:
45+
corepack yarn workspaces focus $(corepack yarn workspaces list --json
46+
| jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io")
47+
print $0 }')
4448
env:
4549
# https://docs.cypress.io/guides/references/advanced-installation#Skipping-installation
4650
CYPRESS_INSTALL_BINARY: 0
@@ -64,7 +68,9 @@ jobs:
6468
})();
6569
EOF
6670
- name: Eject public packages from repo
67-
run: mkdir /tmp/artifacts && corepack yarn workspaces foreach --no-private pack --install-if-needed -o /tmp/artifacts/%s-${{ github.sha }}.tgz
71+
run:
72+
mkdir /tmp/artifacts && corepack yarn workspaces foreach --no-private
73+
pack --install-if-needed -o /tmp/artifacts/%s-${{ github.sha }}.tgz
6874
- name: Upload artifact
6975
if: success()
7076
uses: actions/upload-artifact@v3
@@ -85,18 +91,17 @@ jobs:
8591
with:
8692
path: /tmp/
8793
- name: Extract tarball
88-
run: tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
94+
run:
95+
tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
8996
- name: Add Rollup as a dev dependency
9097
run: >-
91-
npm i --save-dev
92-
@rollup/plugin-commonjs @rollup/plugin-node-resolve
98+
npm i --save-dev @rollup/plugin-commonjs @rollup/plugin-node-resolve
9399
rollup@${{matrix.bundler-version}}
94100
- run: npx rollup --version
95101
- name: Create Rollup config file
96102
run: >-
97-
echo '
98-
import cjs from "@rollup/plugin-commonjs";
99-
import { nodeResolve } from "@rollup/plugin-node-resolve";
103+
echo ' import cjs from "@rollup/plugin-commonjs"; import { nodeResolve
104+
} from "@rollup/plugin-node-resolve";
100105
101106
export default {
102107
input: "./index.mjs",
@@ -124,12 +129,16 @@ jobs:
124129
with:
125130
path: /tmp/
126131
- name: Extract tarball
127-
run: tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
132+
run:
133+
tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
128134
- name: Add Webpack as a dev dependency
129135
run: npm i --save-dev webpack-cli webpack@${{matrix.bundler-version}}
130136
- run: npx webpack --version
131137
- name: Create Webpack config file
132-
run: echo 'module.exports={mode:"production",target:"web",entry:"./index.mjs"}' > webpack.config.js
138+
run:
139+
echo
140+
'module.exports={mode:"production",target:"web",entry:"./index.mjs"}'
141+
> webpack.config.js
133142
- name: Bundle
134143
run: npx webpack
135144

@@ -146,7 +155,8 @@ jobs:
146155
with:
147156
path: /tmp/
148157
- name: Extract tarball
149-
run: tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
158+
run:
159+
tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
150160
- name: Fix package.json to work with Parcel
151161
run: |
152162
node <<'EOF'
@@ -175,12 +185,15 @@ jobs:
175185
with:
176186
path: /tmp/
177187
- name: Extract tarball
178-
run: tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
188+
run:
189+
tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
179190
- name: Add Vite as a dev dependency
180191
run: npm i --save-dev vite@${{matrix.bundler-version}}
181192
- run: npx vite --version
182193
- name: Create index.html
183-
run: echo '<!doctype html><html><head><script type="module" src="./index.mjs"></script></head></html>' > index.html
194+
run:
195+
echo '<!doctype html><html><head><script type="module"
196+
src="./index.mjs"></script></head></html>' > index.html
184197
- name: Bundle
185198
run: npx vite build
186199

@@ -197,11 +210,12 @@ jobs:
197210
with:
198211
path: /tmp/
199212
- name: Extract tarball
200-
run: tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
213+
run:
214+
tar -xzf /tmp/packages/uppy-${{ github.sha }}.tgz --strip-components 1
201215
- name: Add ESBuild as a dev dependency
202216
run: npm i --save-dev esbuild@${{matrix.bundler-version}}
203217
- run: npx esbuild --version
204218
- name: Bundle
205219
run: npx esbuild index.mjs --bundle --outfile=/dev/null
206-
220+
207221
# Browserify: doesn't support ESM.

.github/workflows/ci.yml

+14-6
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: CI
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
paths-ignore:
77
- '**.md'
88
- 'assets/**'
@@ -14,7 +14,7 @@ on:
1414
- '!.github/workflows/ci.yml'
1515
pull_request:
1616
# We want all branches so we configure types to be the GH default again
17-
types: [ opened, synchronize, reopened ]
17+
types: [opened, synchronize, reopened]
1818
paths-ignore:
1919
- '**.md'
2020
- 'assets/**'
@@ -41,7 +41,8 @@ jobs:
4141
uses: actions/checkout@v3
4242
- name: Get yarn cache directory path
4343
id: yarn-cache-dir-path
44-
run: echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
44+
run:
45+
echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
4546

4647
- uses: actions/cache@v3
4748
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
@@ -55,7 +56,10 @@ jobs:
5556
with:
5657
node-version: ${{matrix.node-version}}
5758
- name: Install dependencies
58-
run: corepack yarn workspaces focus $(corepack yarn workspaces list --json | jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io") print $0 }')
59+
run:
60+
corepack yarn workspaces focus $(corepack yarn workspaces list --json
61+
| jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io")
62+
print $0 }')
5963
env:
6064
# https://docs.cypress.io/guides/references/advanced-installation#Skipping-installation
6165
CYPRESS_INSTALL_BINARY: 0
@@ -70,7 +74,8 @@ jobs:
7074
uses: actions/checkout@v3
7175
- name: Get yarn cache directory path
7276
id: yarn-cache-dir-path
73-
run: echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
77+
run:
78+
echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
7479

7580
- uses: actions/cache@v3
7681
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
@@ -84,7 +89,10 @@ jobs:
8489
with:
8590
node-version: lts/*
8691
- name: Install dependencies
87-
run: corepack yarn workspaces focus $(corepack yarn workspaces list --json | jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io") print $0 }')
92+
run:
93+
corepack yarn workspaces focus $(corepack yarn workspaces list --json
94+
| jq -r .name | awk '/^@uppy-example/{ next } { if ($0!="uppy.io")
95+
print $0 }')
8896
env:
8997
# https://docs.cypress.io/guides/references/advanced-installation#Skipping-installation
9098
CYPRESS_INSTALL_BINARY: 0

.github/workflows/companion-deploy.yml

+9-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ name: Companion Edge Deploy
55

66
on:
77
push:
8-
branches: [ 'main' ]
8+
branches: ['main']
99
paths:
1010
- yarn.lock
1111
- 'packages/@uppy/companion/**'
@@ -22,9 +22,15 @@ jobs:
2222
- name: Checkout sources
2323
uses: actions/checkout@v3
2424
- name: Set SHA commit in version
25-
run: (cd packages/@uppy/companion && node -e 'const pkg=require("./package.json");pkg.version+="+${{ github.sha }}";fs.writeFileSync("package.json",JSON.stringify(pkg, undefined, 2)+"\n")')
25+
run:
26+
(cd packages/@uppy/companion && node -e 'const
27+
pkg=require("./package.json");pkg.version+="+${{ github.sha
28+
}}";fs.writeFileSync("package.json",JSON.stringify(pkg, undefined,
29+
2)+"\n")')
2630
- name: Create Companion tarball
27-
run: corepack yarn workspace @uppy/companion pack --install-if-needed -o /tmp/companion-${{ github.sha }}.tar.gz
31+
run:
32+
corepack yarn workspace @uppy/companion pack --install-if-needed -o
33+
/tmp/companion-${{ github.sha }}.tar.gz
2834
- name: Upload artifact
2935
if: success()
3036
uses: actions/upload-artifact@v3

.github/workflows/companion.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
name: Companion
22
on:
33
push:
4-
branches: [ main ]
4+
branches: [main]
55
paths:
66
- yarn.lock
77
- 'packages/@uppy/companion/**'
88
- '.github/workflows/companion.yml'
99
pull_request:
1010
# We want all branches so we configure types to be the GH default again
11-
types: [ opened, synchronize, reopened ]
11+
types: [opened, synchronize, reopened]
1212
paths:
1313
- yarn.lock
1414
- 'packages/@uppy/companion/**'
@@ -29,7 +29,8 @@ jobs:
2929
uses: actions/checkout@v3
3030
- name: Get yarn cache directory path
3131
id: yarn-cache-dir-path
32-
run: echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
32+
run:
33+
echo "dir=$(corepack yarn config get cacheFolder)" >> $GITHUB_OUTPUT
3334

3435
- uses: actions/cache@v3
3536
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
@@ -48,4 +49,3 @@ jobs:
4849
run: corepack yarn run test:companion
4950
- name: Run type checks in focused workspace
5051
run: corepack yarn run build:companion
51-

0 commit comments

Comments
 (0)