Skip to content

Commit

Permalink
Restore Makefile and remove generation of redirects (dbt-labs#3606)
Browse files Browse the repository at this point in the history
resolves dbt-labs#3578

## What are you changing in this pull request and why?

Two things:
1. Restore ability for users to use `make run` and `make build` to
preview/build the docs site while developing locally.
2. Align with the goal in
dbt-labs#3284 to remove
generation of redirects from the Makefile.

## Outstanding questions

### Question 1
The pull request template says the following:
```
- [ ] [Ran link testing](https://github.com/dbt-labs/docs.getdbt.com#running-the-cypress-tests-locally) to update the links that point to the deleted page
```

I'm assuming this is the most up-to-date approach for link testing? I
haven't used it personally yet, so I don't know 🤷

### Question 2

After the changes within this PR, there are no longer any references to
any `make` commands within our README. Do we want to add them anywhere
as an alternative method to running the `npm` commands directly?

## Checklist
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
- [x] Remove unnecessary parts of Makefile
- [x] Add @JKarlavige as a reviewer ("needs technical review")
  • Loading branch information
dbeatty10 authored Jun 22, 2023
1 parent 38d20a5 commit b449b4c
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ You can click a link available in a netlify bot PR comment to see and review you
2. Clone this repo: `git clone https://github.com/dbt-labs/docs.getdbt.com.git`
3. `cd` into the repo: `cd docs.getdbt.com`
4. `cd` into the `website` subdirectory: `cd website`
5. Install the required node packages: `npm install` (optional — install any updates)
6. Build the website: `npm start`
7. Before pushing your changes to a branch, check that all links work by using the `make build` script.
5. Install the required node packages: `make install` or `npm install` (optional — install any updates)
6. Build the website: `make run` or `npm start`
7. Before pushing your changes to a branch, run `make build` or `npm run build` and check that all links work

Advisory:
- If you run into an `fatal error: 'vips/vips8' file not found` error when you run `npm install`, you may need to run `brew install vips`. Warning: this one will take a while -- go ahead and grab some coffee!
Expand Down
10 changes: 10 additions & 0 deletions website/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
.PHONY: run install build

run:
npm start

install:
npm install

build:
DOCS_ENV=build npm run build

0 comments on commit b449b4c

Please sign in to comment.