Skip to content

Commit

Permalink
[Documentation] Add documentation for contributing (#16)
Browse files Browse the repository at this point in the history
* docs: add documentation for contributions
  • Loading branch information
kevinanielsen authored Dec 17, 2023
1 parent 57999b3 commit bf8a21e
Show file tree
Hide file tree
Showing 5 changed files with 90 additions and 11 deletions.
14 changes: 14 additions & 0 deletions docs/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,20 @@ export default defineConfig({
{ label: "Hosting", link: "/go-fast-cdn/guides/hosting/" },
],
},
{
label: "Contribution",
items: [
// Each item here is one entry in the navigation menu.
{
label: "Development",
link: "/contribution/development/",
},
{
label: "Contributing",
link: "/contribution/contributing/",
},
],
},
],
}),
],
Expand Down
18 changes: 18 additions & 0 deletions docs/src/content/docs/contribution/contributing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: Contributing
description: How to help develop the go-fast-cdn.
---

## Go-fast CDN

You can access the source code on [Github](https://github.com/kevinanielsen/go-fast-cdn/), where everyone is encouraged to help in any way they can to make this project better. While you might not be able to contribute to the features of this project, you can still contribute by writing tests, fixing bugs or even fixing typos.

If that is not possible, you can still help by contributing to the [Documentation](#documentation). Even just leaving a star or sharing the project is a great way to contribute.

If you want to report a bug or request a feature, you can go ahead and create a new issue on GitHub, where a template is laid out, and encouraged to be used. If you want to fix a bug or implement a new feature, go ahead and open a pull request with your suggestion.

Please read the [Development Guide](/contribution/development) to learn more about how to develop on this project.

## Documentation

[Github](https://github.com/kevinanielsen/go-fast-cdn/) Is a monorepo, where the documentation can be found in the /docs directory. If you want to request documentation for a feature, go ahead and create a new issue on Github, if you have the solution for an issue or want to edit the documentation, go ahead and fork the project, and when you are ready, open a new pull request.
54 changes: 54 additions & 0 deletions docs/src/content/docs/contribution/development.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
---
title: Development
description: How to help develop the go-fast-cdn.
---

## Installation

### Cloning the repo

You can clone this repo with either of the following commands:

```bash title="SSH"
git clone [email protected]:kevinanielsen/go-fast-cdn
```

```bash title="HTTPS"
git clone https://github.com:kevinanielsen/go-fast-cdn
```

### Setting up the project

This project uses [dotenv](https://dotenv.org) and you can access the `.env.example` [here](https://vault.dotenv.org/project/vlt_a602c18fc8f8fd898bfacba2ed8715a9deca301c87e06fbb3ea2cde40c41e109/example). You can go ahead and copy that, and insert it into your `.env` file.

## Building

This project uses a makefile, and you can use that to build the binaries.

```bash
make prep # install dependencies
make clean # clean the output files (don't use if first time building)
make build # build the binaries
```

This will cross-compile to windows, darwin, and linux binaries, so make sure that you have the compilers installed on your machine if you run `make build`. If you don't have the compiler installed, instead run

```bash
go build .
```

### Running

Your binary should now be built and you can run it with one of the following commands, depending on your system:

```sh title="Windows"
.\bin\go-fast-cdn-windows
```

```bash title="MacOS"
/bin/go-fast-cdn-darwin
```

```bash title="Linux"
/bin/go-fast-cdn-linux
```
4 changes: 4 additions & 0 deletions docs/src/content/docs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,8 @@ import { Card, CardGrid } from "@astrojs/starlight/components";
[Click here](/go-fast-cdn/guides/hosting) to learn how to host your CDN for
free in a docker container.
</Card>
<Card title="Contribute" icon="pen">
[Contribute](/contribution/contributing) to this project. All help is
welcome - Translation, bug fixing, testing, enhancements etc.
</Card>
</CardGrid>
11 changes: 0 additions & 11 deletions docs/src/content/docs/reference/example.md

This file was deleted.

0 comments on commit bf8a21e

Please sign in to comment.