Skip to content

Commit

Permalink
Fix install instructions (CodeYourFuture#831)
Browse files Browse the repository at this point in the history
* Add note about where to look for site setup instructions

* Add Go to homebrew install

Go is now required as we're using Hugo modules, likely as they use Go modules underneath.

* Add .env.example files

These are referenced in the READMEs, and it is required to use the Github token, so is necessary for set up.

* Remove MigraCode as they moved to own repo

Co-authored-by: Sally McGrath <[email protected]>

* Improve example env

---------

Co-authored-by: Sally McGrath <[email protected]>
  • Loading branch information
40thieves and SallyMcGrath authored Jul 30, 2024
1 parent d09c766 commit 244ce3d
Show file tree
Hide file tree
Showing 11 changed files with 60 additions and 6 deletions.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ Each org builds its own Hugo site that uses the common theme and content modules
## Examples

- [CodeYourFuture](/org-cyf/) => [https://org-cyf-theme.netlify.app/](https://org-cyf-theme.netlify.app/)
- [MigraCode](/org-mcb/) => [https://org-mcb-theme.netlify.app/](https://org-mcb-theme.netlify.app/) (couldn't find an svg logo)

## Developing a site

To develop a specific site, `cd` into the relevant sub-directory and follow the instructions in the `README.md` file.

## To build a new site

Expand Down
10 changes: 10 additions & 0 deletions org-cyf-guides/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Allow accessing a GitHub bearer token to avoid rate limits when doing HTTP fetches to the GitHub API.
# This can be generated at https://github.com/settings/tokens?type=beta and needs read-only access to all public CYF GitHub repos.
HUGO_CURRICULUM_GITHUB_BEARER_TOKEN=""

# Client ID and secret for the GitHub OAuth app used to authenticate users.
GITHUB_CLIENT_ID="clientid"
GITHUB_CLIENT_SECRET="clientsecret"

# The domain of the site, used for generating redirect URLs.
DOMAIN="http://localhost:1313"
2 changes: 1 addition & 1 deletion org-cyf-guides/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ path = "github.com/CodeYourFuture/curriculum/org-cyf-piscine"
### To install

```bash
brew install hugo
brew install go hugo
```

### To run locally
Expand Down
10 changes: 10 additions & 0 deletions org-cyf-itp/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Allow accessing a GitHub bearer token to avoid rate limits when doing HTTP fetches to the GitHub API.
# This can be generated at https://github.com/settings/tokens?type=beta and needs read-only access to all public CYF GitHub repos.
HUGO_CURRICULUM_GITHUB_BEARER_TOKEN=""

# Client ID and secret for the GitHub OAuth app used to authenticate users.
GITHUB_CLIENT_ID="clientid"
GITHUB_CLIENT_SECRET="clientsecret"

# The domain of the site, used for generating redirect URLs.
DOMAIN="http://localhost:1313"
3 changes: 2 additions & 1 deletion org-cyf-itp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
### To install

```bash
brew install hugo
brew install go hugo
```

### To run locally
Expand All @@ -34,6 +34,7 @@ The "Repository access" you need is "Public repositories (read-only)", and you d
<summary>Open to view screenshot of the required permissions</summary>

![screenshot of required permissions](./readme_repository_access.png)

</details>

#### Set up `.env`
Expand Down
10 changes: 10 additions & 0 deletions org-cyf-piscine/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Allow accessing a GitHub bearer token to avoid rate limits when doing HTTP fetches to the GitHub API.
# This can be generated at https://github.com/settings/tokens?type=beta and needs read-only access to all public CYF GitHub repos.
HUGO_CURRICULUM_GITHUB_BEARER_TOKEN=""

# Client ID and secret for the GitHub OAuth app used to authenticate users.
GITHUB_CLIENT_ID="clientid"
GITHUB_CLIENT_SECRET="clientsecret"

# The domain of the site, used for generating redirect URLs.
DOMAIN="http://localhost:1313"
2 changes: 1 addition & 1 deletion org-cyf-piscine/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ path = "github.com/CodeYourFuture/curriculum/org-cyf-piscine"
### To install

```bash
brew install hugo
brew install go hugo
```

### To run locally
Expand Down
10 changes: 10 additions & 0 deletions org-cyf-sdc/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Allow accessing a GitHub bearer token to avoid rate limits when doing HTTP fetches to the GitHub API.
# This can be generated at https://github.com/settings/tokens?type=beta and needs read-only access to all public CYF GitHub repos.
HUGO_CURRICULUM_GITHUB_BEARER_TOKEN=""

# Client ID and secret for the GitHub OAuth app used to authenticate users.
GITHUB_CLIENT_ID="clientid"
GITHUB_CLIENT_SECRET="clientsecret"

# The domain of the site, used for generating redirect URLs.
DOMAIN="http://localhost:1313"
2 changes: 1 addition & 1 deletion org-cyf-sdc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
### To install

```bash
brew install hugo
brew install go hugo
```

### To run locally
Expand Down
10 changes: 10 additions & 0 deletions org-cyf/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Allow accessing a GitHub bearer token to avoid rate limits when doing HTTP fetches to the GitHub API.
# This can be generated at https://github.com/settings/tokens?type=beta and needs read-only access to all public CYF GitHub repos.
HUGO_CURRICULUM_GITHUB_BEARER_TOKEN=""

# Client ID and secret for the GitHub OAuth app used to authenticate users.
GITHUB_CLIENT_ID="clientid"
GITHUB_CLIENT_SECRET="clientsecret"

# The domain of the site, used for generating redirect URLs.
DOMAIN="http://localhost:1313"
2 changes: 1 addition & 1 deletion org-cyf/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
### To install

```bash
brew install hugo
brew install go hugo
```

### To run locally
Expand Down

0 comments on commit 244ce3d

Please sign in to comment.