Skip to content

Commit 0d45919

Browse files
committed
update CI config for flattened dir struc
1 parent e132743 commit 0d45919

File tree

5 files changed

+9
-14
lines changed

5 files changed

+9
-14
lines changed

.circleci/config.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ jobs:
2424
- run:
2525
name: Install Gatsby
2626
command: |
27-
cd gatsby
2827
npm ci
2928
- run:
3029
name: Import Gatsby Tokens
@@ -36,12 +35,11 @@ jobs:
3635
- run:
3736
name: Gatsby Build
3837
command: |
39-
cd gatsby
4038
./node_modules/gatsby/node_modules/.bin/gatsby build --prefix-paths
4139
- run:
4240
name: Remove empty directories
4341
command: |
44-
find ~/build/gatsby/public -type d -empty -delete
42+
find ~/build/public -type d -empty -delete
4543
- run:
4644
name: Check for merge conflicts
4745
command: .circleci/scripts/merge_conflicts.sh
@@ -65,7 +63,6 @@ jobs:
6563
- run:
6664
name: Serve Gatsby
6765
command: |
68-
cd gatsby
6966
./node_modules/gatsby/node_modules/.bin/gatsby serve --prefix-paths
7067
background: true
7168
- run:
@@ -128,7 +125,7 @@ jobs:
128125
name: Lighthouse Audit
129126
command: .circleci/tests/lighthouse/run
130127
- store_artifacts:
131-
path: gatsby/lighthouse_data/
128+
path: lighthouse_data/
132129
destination: lighthouse_data/
133130

134131
deploy:

.circleci/scripts/functions.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@ protected-branches() {
3131

3232
gatsby-tokens() {
3333
# Set GitHub API token
34-
touch $BUILD_PATH/gatsby/.env.production
35-
echo "GITHUB_API=$GITHUB_TOKEN" > $BUILD_PATH/gatsby/.env.production
36-
echo "SEGMENT_KEY=$SEGMENT_KEY" >> $BUILD_PATH/gatsby/.env.production
34+
touch $BUILD_PATH/.env.production
35+
echo "GITHUB_API=$GITHUB_TOKEN" > $BUILD_PATH/.env.production
36+
echo "SEGMENT_KEY=$SEGMENT_KEY" >> $BUILD_PATH/.env.production
3737
echo "GTM_ID=$GTM_ID" >> .env.production
3838
}
3939

.circleci/scripts/manual-deploy.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@ if [[ $ENV == "live" && $SITE_UUID == "72e163bd-0054-4332-8bf8-219c50b78581" ]];
1616
else
1717
echo Deploying to the $ENV environment on the $SITE_NAME site...
1818

19-
# Move to the Gatsby directory
20-
cd gatsby
2119

2220
# Ask user if they want to regenerate Gatsby output
2321
read -p "Would you like to rebuild the Docs site? (Yy/Nn)" -n 1 -r

.circleci/tests/lighthouse/run

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ echo -e "\nProcessing pull request #$CIRCLE_PR_NUMBER"
1919

2020
# Lighthouse audits
2121
echo -e "\nRunning lighthouse audits..."
22-
cd $BUILD_PATH/gatsby
22+
cd $BUILD_PATH/
2323
npm run lighthouse-run
2424

2525
# Create the artifacts directory if needed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ git@github.com:pantheon-systems/documentation.git
4545
### Install
4646

4747
```
48-
cd documentation/gatsby
48+
cd documentation/
4949
npm ci
5050
```
5151
#### GitHub Token
@@ -55,7 +55,7 @@ We use the [gatsby-remark-embed-snippet](https://github.com/gatsbyjs/gatsby/tree
5555
1. Click Generate new token
5656
1. Give it a name and click the public_repo checkbox, then the Generate Token button at the bottom
5757
1. Copy the token to your clipboard.
58-
1. Create or edit `gatsby/.env.development`, and add (replacing $TOKENHASH ):
58+
1. Create or edit `.env.development`, and add (replacing $TOKENHASH ):
5959

6060
```
6161
GITHUB_API=$TOKENHASH
@@ -64,7 +64,7 @@ We use the [gatsby-remark-embed-snippet](https://github.com/gatsbyjs/gatsby/tree
6464
### Run
6565

6666
```
67-
cd documentation/gatsby
67+
cd documentation/
6868
gatsby develop
6969
```
7070

0 commit comments

Comments
 (0)