Repository navigation
Expand file tree
/
Copy pathconfig.github.toml
More file actions
32 lines (28 loc) · 1.62 KB
/
Copy pathconfig.github.toml
File metadata and controls
32 lines (28 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# upgit config. GitHub is the default uploader.
# Fill pat, username, repo, branch below. Repo must be public.
# PAT: https://github.com/settings/tokens (classic: repo scope; fine-grained: Contents Read and Write on this repo).
# To use another host (SM.MS, S3, OSS, Qiniu, ...): copy a [uploaders.*] table from
# config.sample.toml in the upgit GitHub repository, set default to that table name.
# Example SM.MS:
# default = "smms"
# [uploaders.smms]
# token = "..."
# Which uploader table to use.
default = "github"
# Remote object key template. Placeholders: {year} {month} {day} {hour} {minute} {second} {unix} {unix_tsms} {stem} {fname} {fullname} {ext} {hmac} {fname_hash} {fname_hash4} {fname_hash8} {content_hash} {content_hash4} {content_hash8}. {fname_hash} and {content_hash} are xxHash32 (seed 0); {hmac} is HMAC-SHA256.
naming = "{year}/{month}/upgit_{year}{month}{day}_{unix}{ext}"
# Optional HMAC secret for the {hmac} placeholder in naming. Any random string works.
# hmac_key = "YOUR_HMAC_KEY"
# Template whose interpolation is HMAC-SHA256 hashed to produce {hmac}.
# hmac_format = "{year}_{month}_{day}_{unix}{ext}"
# Truncate the hex digest to this many characters. Omit for the full hash.
# hmac_len = 31
[uploaders.github]
# Personal access token with "repo" scope (classic) or Contents Read and Write (fine-grained). Create: https://github.com/settings/tokens
pat = "PASTE_YOUR_TOKEN"
# GitHub username that owns the repo.
username = "..."
# Public repository name. Private repos make raw URLs 404.
repo = "..."
# Branch to commit into. Omit or leave empty to use the repository default (main or master).
# branch = "main"