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
## How to use (GitHub Actions) - Advanced examples
134
+
135
+
#### [More info in EXAMPLES.md](./EXAMPLES.md)
136
+
133
137
## How to use (local)
134
138
135
139
Set the `GITHUB_TOKEN` environment variable to the value of "personal access token".
@@ -151,106 +155,6 @@ npm run build
151
155
node . USER_NAME
152
156
```
153
157
154
-
## Advanced example: automatic day/night switching + keeping output in other branch
155
-
156
-
This alternative workflow generates two files, `day.svg` and `night.svg`, and pushes it to `output-3d-contrib` branch, keeping the main repo 'clean' from build artifacts.
157
-
158
-
### step 1. Create special repository ([see above](#step-1-create-special-repository))
159
-
### step 2. Create `conf/github-profile-3d-contrib.json` file in your <username> repo:
160
-
```json:conf/github-profile-3d-contrib.json
161
-
[
162
-
{
163
-
"type": "normal",
164
-
"fileName": "day.svg",
165
-
"backgroundColor": "#ffffff",
166
-
"foregroundColor": "#00000f",
167
-
"strongColor": "#111133",
168
-
"weakColor": "gray",
169
-
"radarColor": "#47a042",
170
-
"growingAnimation": true,
171
-
"contribColors": [
172
-
"#efefef",
173
-
"#d8e887",
174
-
"#8cc569",
175
-
"#47a042",
176
-
"#1d6a23"
177
-
]
178
-
},
179
-
{
180
-
"type": "rainbow",
181
-
"fileName": "night.svg",
182
-
"backgroundColor": "#00000f",
183
-
"foregroundColor": "#eeeeff",
184
-
"strongColor": "rgb(255,200,55)",
185
-
"weakColor": "#aaaaaa",
186
-
"radarColor": "rgb(255,200,55)",
187
-
"growingAnimation": true,
188
-
"saturation": "50%",
189
-
"contribLightness": [
190
-
"20%",
191
-
"30%",
192
-
"35%",
193
-
"40%",
194
-
"50%"
195
-
],
196
-
"duration": "10s",
197
-
"hueRatio": -7
198
-
}
199
-
]
200
-
```
201
-
202
-
### step 3. Create `.github/workflows/profile-3d-contrib.yml` workflow file in your <username> repo:
203
-
```yaml:.github/workflows/profile-3d-contrib.yml
204
-
name: generate 3d chart for profile contributions
205
-
206
-
on:
207
-
# run automatically every 24 hours
208
-
schedule:
209
-
- cron: "0 */24 * * *"
210
-
211
-
# allows to manually run the job at any time
212
-
workflow_dispatch:
213
-
214
-
# run on every push on the main branch
215
-
# don't forget to change if you're using 'master' branch
0 commit comments