Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
612889df
Unverified
Commit
612889df
authored
Jul 01, 2021
by
JJ Kasper
Committed by
GitHub
Jul 01, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update repo scripts to separate folder (#26787)
parent
b508d904
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
54 additions
and
7 deletions
+54
-7
build_test_deploy.yml
.github/workflows/build_test_deploy.yml
+4
-4
package.json
package.json
+1
-0
check-examples.sh
scripts/check-examples.sh
+0
-2
check-pre-compiled.sh
scripts/check-pre-compiled.sh
+0
-0
next-with-deps.sh
scripts/next-with-deps.sh
+39
-0
publish-release.sh
scripts/publish-release.sh
+0
-0
release-stats.sh
scripts/release-stats.sh
+0
-0
test-pnp.sh
scripts/test-pnp.sh
+0
-0
skip-docs-change.js
skip-docs-change.js
+10
-1
No files found.
.github/workflows/build_test_deploy.yml
View file @
612889df
...
@@ -55,7 +55,7 @@ jobs:
...
@@ -55,7 +55,7 @@ jobs:
with
:
with
:
path
:
./*
path
:
./*
key
:
${{ github.sha }}
key
:
${{ github.sha }}
-
run
:
./check-pre-compiled.sh
-
run
:
./
scripts/
check-pre-compiled.sh
if
:
${{needs.build.outputs.docsChange != 'docs only change'}}
if
:
${{needs.build.outputs.docsChange != 'docs only change'}}
testUnit
:
testUnit
:
...
@@ -146,7 +146,7 @@ jobs:
...
@@ -146,7 +146,7 @@ jobs:
path
:
./*
path
:
./*
key
:
${{ github.sha }}
key
:
${{ github.sha }}
-
run
:
bash ./test-pnp.sh
-
run
:
bash ./
scripts/
test-pnp.sh
if
:
${{needs.build.outputs.docsChange != 'docs only change'}}
if
:
${{needs.build.outputs.docsChange != 'docs only change'}}
testsPass
:
testsPass
:
...
@@ -251,7 +251,7 @@ jobs:
...
@@ -251,7 +251,7 @@ jobs:
path
:
./*
path
:
./*
key
:
${{ github.sha }}
key
:
${{ github.sha }}
-
run
:
./publish-release.sh
-
run
:
./
scripts/
publish-release.sh
prStats
:
prStats
:
name
:
Release Stats
name
:
Release Stats
...
@@ -263,7 +263,7 @@ jobs:
...
@@ -263,7 +263,7 @@ jobs:
with
:
with
:
path
:
./*
path
:
./*
key
:
${{ github.sha }}
key
:
${{ github.sha }}
-
run
:
./release-stats.sh
-
run
:
./
scripts/
release-stats.sh
-
uses
:
./.github/actions/next-stats-action
-
uses
:
./.github/actions/next-stats-action
env
:
env
:
PR_STATS_COMMENT_TOKEN
:
${{ secrets.PR_STATS_COMMENT_TOKEN }}
PR_STATS_COMMENT_TOKEN
:
${{ secrets.PR_STATS_COMMENT_TOKEN }}
package.json
View file @
612889df
...
@@ -34,6 +34,7 @@
...
@@ -34,6 +34,7 @@
"publish-canary"
:
"lerna version prerelease --preid canary --force-publish && release --pre --skip-questions"
,
"publish-canary"
:
"lerna version prerelease --preid canary --force-publish && release --pre --skip-questions"
,
"publish-stable"
:
"lerna version --force-publish"
,
"publish-stable"
:
"lerna version --force-publish"
,
"lint-staged"
:
"lint-staged"
,
"lint-staged"
:
"lint-staged"
,
"next-with-deps"
:
"./scripts/next-with-deps.sh"
,
"next"
:
"node --trace-deprecation --enable-source-maps packages/next/dist/bin/next"
,
"next"
:
"node --trace-deprecation --enable-source-maps packages/next/dist/bin/next"
,
"debug"
:
"node --inspect packages/next/dist/bin/next"
"debug"
:
"node --inspect packages/next/dist/bin/next"
},
},
...
...
check-examples.sh
→
scripts/
check-examples.sh
View file @
612889df
#!/bin/bash
#!/bin/bash
cd
`
dirname
$0
`
for
folder
in
examples/
*
;
do
for
folder
in
examples/
*
;
do
cp
-n
packages/create-next-app/templates/default/gitignore
$folder
/.gitignore
;
cp
-n
packages/create-next-app/templates/default/gitignore
$folder
/.gitignore
;
if
[
-f
"
$folder
/package.json"
]
;
then
if
[
-f
"
$folder
/package.json"
]
;
then
...
...
check-pre-compiled.sh
→
scripts/
check-pre-compiled.sh
View file @
612889df
File moved
scripts/next-with-deps.sh
0 → 100755
View file @
612889df
#!/bin/bash
START_DIR
=
$PWD
# gets last argument which should be the project dir
for
PROJECT_DIR
in
$@
;
do
:
;
done
if
[
-z
$PROJECT_DIR
]
;
then
echo
"No project directory provided, exiting..."
exit
1
;
fi
;
if
[
!
-d
$PROJECT_DIR
]
;
then
echo
"Invalid project directory provided, exiting..."
exit
1
;
fi
;
if
[
$PROJECT_DIR
==
$PWD
]
||
[
"
$PROJECT_DIR
"
==
"."
]
;
then
echo
"Project directory can not be root, exiting..."
exit
1
;
fi
;
CONFLICTING_DEPS
=(
"react"
"react-dom"
"styled-jsx"
"next"
)
for
dep
in
${
CONFLICTING_DEPS
[@]
}
;
do
if
[
-d
"
$PROJECT_DIR
/node_modules/
$dep
"
]
;
then
HAS_CONFLICTING_DEP
=
"yup"
fi
;
done
if
[
!
-z
$HAS_CONFLICTING_DEP
]
||
[
!
-d
"
$PROJECT_DIR
/node_modules"
]
;
then
cd
$PROJECT_DIR
yarn
install
for
dep
in
${
CONFLICTING_DEPS
[@]
}
;
do
rm
-rf
node_modules/
$dep
done
fi
cd
$START_DIR
yarn next
$@
publish-release.sh
→
scripts/
publish-release.sh
View file @
612889df
File moved
release-stats.sh
→
scripts/
release-stats.sh
View file @
612889df
File moved
test-pnp.sh
→
scripts/
test-pnp.sh
View file @
612889df
File moved
skip-docs-change.js
View file @
612889df
...
@@ -3,7 +3,16 @@ const { exec: execOrig, spawn } = require('child_process')
...
@@ -3,7 +3,16 @@ const { exec: execOrig, spawn } = require('child_process')
const
exec
=
promisify
(
execOrig
)
const
exec
=
promisify
(
execOrig
)
const
DOCS_FOLDERS
=
[
'bench'
,
'docs'
,
'errors'
,
'examples'
]
const
DOCS_FOLDERS
=
[
'bench'
,
'docs'
,
'errors'
,
'examples'
,
'UPGRADING.md'
,
'contributing.md'
,
'CODE_OF_CONDUCT.md'
,
'readme.md'
,
]
async
function
main
()
{
async
function
main
()
{
await
exec
(
'git fetch origin canary'
)
await
exec
(
'git fetch origin canary'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment