Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP GUI path for contributing instructions #1969

Open
wants to merge 52 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
8b2bcd7
Update download instructions
joonas-somero Dec 18, 2023
0c90b89
Add .vscode
joonas-somero Jan 11, 2024
657bbcf
Fallback for environments where Git is not available
joonas-somero Jan 11, 2024
f3ecc03
Started with adding a GUI option
joonas-somero Jan 11, 2024
c50f820
Merge branch 'master' into getting-gui
joonas-somero Jan 11, 2024
cd137f0
Some useful workspace settings
joonas-somero Jan 24, 2024
10f47b2
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Jan 24, 2024
78c0e52
Define type for every task separately
joonas-somero Jan 24, 2024
12e7dc2
Colorcoded icons for tasks
joonas-somero Jan 24, 2024
833afa3
Add task for running the scripts
joonas-somero Jan 24, 2024
08fbf45
Allow for disabling plugin in environment
joonas-somero Jan 24, 2024
40fe3c5
Focus terminal on tasks, excluding serve task
joonas-somero Jan 24, 2024
cade432
Move environment variable into 'options'
joonas-somero Jan 24, 2024
4ca1391
Silence warnings when running locally by disabling plugin
joonas-somero Jan 24, 2024
047ce8b
Set default terminal profiles
joonas-somero Jan 24, 2024
0366544
Small updates to documentation
joonas-somero Jan 26, 2024
a33954c
Reformat for clarity
joonas-somero Jan 26, 2024
aa27b84
Link to instructions at GitHub as Option 2
joonas-somero Jan 26, 2024
71266c4
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Feb 14, 2024
7ad0e14
Add VS Code installation
joonas-somero Feb 22, 2024
9ee77db
Instruct to consult IT support before installing
joonas-somero Feb 22, 2024
2fedd9f
Adjust whitespace
joonas-somero Feb 22, 2024
1b787b4
Minor reorganization
joonas-somero Feb 22, 2024
90e46f4
Normalize file permissions and line endings
joonas-somero Feb 22, 2024
3b5f94b
Split installation into two parts
joonas-somero Feb 22, 2024
8a22b2a
Reword, introduce alternatives
joonas-somero Feb 22, 2024
1e24af0
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Feb 22, 2024
1d680df
Merge branch 'master' into getting-gui
joonas-somero Mar 14, 2024
1f54a2d
Clarify task labels with details
joonas-somero Mar 14, 2024
96acad0
Fix quotes, whitespace
joonas-somero Mar 14, 2024
6d41bc6
Revert to activating the environment on Windows
joonas-somero Mar 15, 2024
15a5a7d
Update screenshot
joonas-somero Mar 15, 2024
cbebb03
Add 'click to expand'
joonas-somero Mar 15, 2024
0656909
Misc additions
joonas-somero Mar 15, 2024
25459e1
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Mar 15, 2024
5fda27a
Add comment on environment
joonas-somero Mar 22, 2024
a061e1b
Use task names in output
joonas-somero Mar 22, 2024
332287a
Update task panel settings
joonas-somero Mar 22, 2024
33cc317
Add a confirmation dialog with a warning before running scripts
joonas-somero Mar 22, 2024
2a630a4
Remove search parameters for specific platform/app
joonas-somero Mar 22, 2024
53a5201
Extend note
joonas-somero Mar 22, 2024
3b136c1
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Mar 22, 2024
7602d78
Remove unused images
joonas-somero Mar 28, 2024
8c51967
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Mar 28, 2024
3985688
Emphasize note
joonas-somero Apr 18, 2024
3e6af46
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero May 17, 2024
8b4f300
Merge branch 'master' into getting-gui
joonas-somero May 22, 2024
3fb9560
Comment out terminal profile change
joonas-somero May 31, 2024
fb9272b
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Jun 13, 2024
277d244
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Sep 13, 2024
5ebcd48
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Sep 26, 2024
4514e8d
Merge remote-tracking branch 'origin/master' into getting-gui
joonas-somero Oct 2, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 13 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,19 @@ CSC staff: do these two things _first_:
2. Then [join here the CSC employees team](https://github.com/orgs/CSCfi/teams/employees/members). Membership
gives you permissions to edit source files that build the user guide. (Wait for a confirmation email.)

The rest of this document describes the workflow in Github as well as instructions for previewing and deploying the documentation. See [Style guide](STYLEGUIDE.md) for content and formatting instructions and [Frequently Asked Questions](FAQ.md) for more in depth explanations of common questions you might encounter while contributing.
The rest of this document describes the workflow in Github as well as instructions for previewing and
deploying the documentation. There are more resources available, though:

- [STYLEGUIDE.md](STYLEGUIDE.md) — Content and formatting instructions
- [FAQ.md](FAQ.md) — More in-depth explanations of common questions you might encounter while contributing
- [GETTING_STARTED.md](GETTING_STARTED.md) — Setting up a local development environment
- [Reference card](docs.csc.fi/ref) — On the available elements
- [Markdown source for Reference card](docs/ref.md)

## For the impatient

Once you've completed the steps above:

* In [docs.csc.fi](https://docs.csc.fi) go to the page you want to edit and click the pen icon at top right
* (sign in to GitHub) and edit the content
* Scroll down to commit changes (create a new branch) -> make a pull request
Expand Down Expand Up @@ -60,7 +68,7 @@ must use pull requests.
- If your commits aren't showing up on the pull request, i.e., the pull request isn't updating when making new commits, try switching the base branch ('Edit' button, top-right) from `master` to something else and then back again.
- Write meaningful pull request messages, so it is easier for reviewers to do their job.
- Communicate! Use "WIP" (= Work In Progress) in your pull request title, if you don't wish the branch to be merged to master (i.e. you want to continue working with it).
- Once your PR has been accepted, remove the temporary branch (if not deleted by an admin at merge)
- Once your PR has been accepted, remove the temporary branch (if not deleted automatically at merge)

#### Reviewer

Expand All @@ -79,7 +87,7 @@ If you get a request to review a pull request, please contribute to help publish
If you see an approved branch:

- "Squash and merge" it
- Delete the (now unnecessary) branch
- Delete the (now unnecessary) branch (if not deleted automatically at merge)
- Occasionally the number of (unnecessary) branches grows: prune.

**Note:** If you make bigger changes to the (main) categories / menu on the left, it might affect some links used on our webpages. Please communicate these changes, for example in the RC-channel #research.csc.fi.
Expand Down Expand Up @@ -141,7 +149,8 @@ git push origin your_branch_name
```

Now, in the GitHub web GUI you can create a pull request, ask a person to review
it and (some admin to) merge the changes. After the PR has been merged, the branch on github can be deleted.
it and (some admin to) merge the changes. After the PR has been merged, the branch
on GitHub should get deleted automatically (delete manually if not).

**Tip 1.** Git uses [Vim](https://www.vim.org) as the default editor for commit
messages. It is possible to change the default editor, but below are
Expand Down
47 changes: 28 additions & 19 deletions FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,21 +119,22 @@ Common issues:
Tests are run to check, for example, that your pull request complies with the CSC Docs style guide and that there are no broken links. If any such errors are found in your commits, the tests will not pass and you need to figure out what went wrong:

1. Find out which tests did not pass under the notification `Some checks were not successful` in the Review-dialogue (marked with a red x and text `Failing after X - Build Failed`).
2. To the right of the failed test, click `Details`, which opens the `Checks` tab.
3. Under the `Build Failed` section, click the link at `The build failed` to open the Travis CI page with logged details on the build.
4. Scan through the Job log for any text marked in red. These are errors that the test found, and the reason for them is written before the red text.
5. An example error is shown below. Here, the `link_check.py` test script was run to see whether any links were broken. The test found two broken section links and it tells you in which files and on which lines the errors are.

```console
$ python3 tests/python_link_tests/link_check.py
The section link namd.md#batch-script-example-for-mahti in file docs/apps/namd.md on line 33 is broken
The section link cp2k.md#example-batch-script-for-mahti-using-mixed-mpi-openmp-parallelization in file docs/apps/cp2k.md on line 81 is broken
No broken file links found
No hidden files found
The command "python3 tests/python_link_tests/link_check.py" exited with 1.
```

6. Fix the errors, commit and push the revised files to the same branch and the tests should now pass.
1. To the right of the failed test, click `Details`, which opens the `Checks` tab.
1. Under the `Build Failed` section, click the link at `The build failed` to open the Travis CI page with logged details on the build.
- Alternatively, look for your PR in the [list of csc-user-guide pull requests at Travis CI](https://app.travis-ci.com/github/CSCfi/csc-user-guide/pull_requests).
1. Scan through the Job log for any text marked in red. These are errors that the test found, and the reason for them is written before the red text.
1. An example error is shown below. Here, the `link_check.py` test script was run to see whether any links were broken. The test found two broken section links and it tells you in which files and on which lines the errors are.

```console
$ python3 tests/python_link_tests/link_check.py
The section link namd.md#batch-script-example-for-mahti in file docs/apps/namd.md on line 33 is broken
The section link cp2k.md#example-batch-script-for-mahti-using-mixed-mpi-openmp-parallelization in file docs/apps/cp2k.md on line 81 is broken
No broken file links found
No hidden files found
The command "python3 tests/python_link_tests/link_check.py" exited with 1.
```

1. Fix the errors, commit and push the revised files to the same branch and the tests should now pass.

## How can I preview my edits?

Expand Down Expand Up @@ -177,13 +178,21 @@ pip install -r requirements.txt

#### Conda

Detailed instructions for installing Conda on Windows are found [here](GETTING_STARTED.md#setting-up-a-development-environment-on-windows), but the gist of it, regardless of the operating system used, is to install [Miniconda](https://docs.conda.io/projects/miniconda/en/latest/) and to use it to create the virtual environment. So, with Miniconda installed, an environment containing everything needed to run MkDocs can be created by running the command
Detailed instructions for installing Conda on Windows are found [here](GETTING_STARTED.md#setting-up-a-development-environment-on-windows), but the gist of it, regardless of the operating system used, is to install [Miniconda](https://docs.conda.io/projects/miniconda/en/latest/), use it to create a virtual environment to install the requirements in. So, with Miniconda installed, an environment to run MkDocs in can be created by running the command

```bash
conda env create -f docs/support/tutorials/conda/conda-docs-env-freeze.yaml
conda env create -f development/conda-docs-base-1.0.yaml
```

Add a `--force` flag if you already have a Conda environment named `docs-env` (you got `CondaValueError: prefix already exists: [...]`) and want to overwrite it. Activate the new environment with
Add a `--force` flag if you already have a Conda environment named `docs-env` (you got `CondaValueError: prefix already exists: [...]`) and want to overwrite it. The environment is now ready for installing the requirements.

```bash
conda run -n docs-env pip install -r requirements.txt
```

If you want to reinstall the dependencies, add a `--force-reinstall` flag to the Pip command.

Activate the new environment with

```bash
conda activate docs-env
Expand Down Expand Up @@ -213,7 +222,7 @@ You can also run the tests locally with
bash tests/run_tests.sh
```

The tests depend on the Conda environment, so remember to activate it before running them.
The tests depend on the Conda environment, so remember to activate it before running them, or use `conda run -n docs-env bash tests/run_tests.sh`.

#### Scripts

Expand Down
Loading