You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert

12
+
[](https://www.repostatus.org/#active)
[](https://www.repostatus.org/#active)
- Click [here](https://github.com/insightsengineering/r.pkg.template/generate) to generate a copy of this template directly within GitHub.
67
+
* Click [here](https://github.com/insightsengineering/r.pkg.template/generate) to generate a copy of this template directly within GitHub.
56
68
57
-
- Clone the repository from your account/organization.
69
+
* Clone the repository from your account/organization.
58
70
59
-
- Run the initializer script:
71
+
* Run the initializer script:
60
72
61
73
```bash
62
74
./init.sh
@@ -68,7 +80,7 @@ All CI/CD jobs are defined in the [.github/workflows](./.github/workflows) direc
68
80
69
81
All workflows originating from this repository can be repurposed by other R package GitHub repositories.
70
82
71
-
For more information including detailed description and screenshots of workflows, please refer to [Workflows](./workflows.md).
83
+
👉 For more information including detailed description and screenshots of workflows, please refer to the [Workflows documentation](./workflows.md).
72
84
73
85
### Pre-commit
74
86
@@ -80,32 +92,29 @@ code formatting and spell checks.
80
92
81
93
### Setting up pre-commit for R project
82
94
83
-
1. Install the `pre-commit` framework. Use the official [installation guide][pre-commit installation].
84
-
2. Install R package `precommit`
95
+
* Install the `pre-commit` framework. Use the official [installation guide][pre-commit installation].
85
96
86
-
```sh
87
-
R -e 'install.packages("precommit")'
88
-
```
97
+
* Install R package `precommit`
89
98
90
-
1. Run the `use_precommit()` function to generate an example pre-commit configuration called `.pre-commit-config.yaml`:
99
+
```sh
100
+
R -e 'install.packages("precommit")'
101
+
```
91
102
92
-
```sh
93
-
[ !-f".pre-commit-config.yaml" ] && R -e 'precommit::use_precommit()'
94
-
```
103
+
* Run the `use_precommit()` function to generate an example pre-commit configuration called `.pre-commit-config.yaml`:
95
104
96
-
1. Install the git hooks script:
105
+
```sh
106
+
[ !-f".pre-commit-config.yaml" ] && R -e 'precommit::use_precommit()'
107
+
```
97
108
98
-
```sh
99
-
pre-commit install
100
-
```
109
+
* Install the git hooks script:
110
+
111
+
```sh
112
+
pre-commit install
113
+
```
101
114
102
-
1. From this moment all scripts from `.pre-commit-config.yaml` will run before every `git commit`
103
-
command. If you want to run them manually without committing you can use command
104
-
`pre-commit run --all-files`. For more information refer official [pre-commit] documentation.
115
+
* From this moment on, all scripts from `.pre-commit-config.yaml` will run before every `git commit` command. If you want to run them manually without committing you can use command `pre-commit run --all-files`. For more information, please refer to the official [pre-commit] documentation.
105
116
106
-
> NOTE:
107
-
> Frequently run `pre-commit autoupdate` to update all repositories
108
-
> in `.pre-commit-config.yaml`.
117
+
> NOTE: Frequently run `pre-commit autoupdate` to update all hooks in the `.pre-commit-config.yaml` configuration file.
0 commit comments