Skip to content

Commit

Permalink
gendocs: add autogenerated header to all docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ncw committed Feb 10, 2020
1 parent 25cfeb2 commit dfb710e
Show file tree
Hide file tree
Showing 70 changed files with 140 additions and 69 deletions.
1 change: 1 addition & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ with modules beneath.
* ...commands
* docs - the documentation and website
* content - adjust these docs only - everything else is autogenerated
* command - these are auto generated - edit the corresponding .go file
* fs - main rclone definitions - minimal amount of code
* accounting - bandwidth limiting and statistics
* asyncreader - an io.Reader which reads ahead
Expand Down
4 changes: 3 additions & 1 deletion cmd/gendocs/gendocs.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ date: %s
title: "%s"
slug: %s
url: %s
# autogenerated - DO NOT EDIT, instead edit the source code in %s and as part of making a release run "make commanddocs"
---
`

Expand Down Expand Up @@ -67,7 +68,8 @@ rclone.org website.`,
name := filepath.Base(filename)
base := strings.TrimSuffix(name, path.Ext(name))
url := "/commands/" + strings.ToLower(base) + "/"
return fmt.Sprintf(gendocFrontmatterTemplate, now, strings.Replace(base, "_", " ", -1), base, url)
source := strings.Replace(strings.Replace(base, "rclone", "cmd", -1), "_", "/", -1) + "/"
return fmt.Sprintf(gendocFrontmatterTemplate, now, strings.Replace(base, "_", " ", -1), base, url, source)
}
linkHandler := func(name string) string {
base := strings.TrimSuffix(name, path.Ext(name))
Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone"
slug: rclone
url: /commands/rclone/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/ and as part of making a release run "make commanddocs"
---
## rclone

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_about.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone about"
slug: rclone_about
url: /commands/rclone_about/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/about/ and as part of making a release run "make commanddocs"
---
## rclone about

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_authorize.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone authorize"
slug: rclone_authorize
url: /commands/rclone_authorize/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/authorize/ and as part of making a release run "make commanddocs"
---
## rclone authorize

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_cachestats.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone cachestats"
slug: rclone_cachestats
url: /commands/rclone_cachestats/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/cachestats/ and as part of making a release run "make commanddocs"
---
## rclone cachestats

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_cat.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone cat"
slug: rclone_cat
url: /commands/rclone_cat/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/cat/ and as part of making a release run "make commanddocs"
---
## rclone cat

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_check.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone check"
slug: rclone_check
url: /commands/rclone_check/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/check/ and as part of making a release run "make commanddocs"
---
## rclone check

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_cleanup.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone cleanup"
slug: rclone_cleanup
url: /commands/rclone_cleanup/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/cleanup/ and as part of making a release run "make commanddocs"
---
## rclone cleanup

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config"
slug: rclone_config
url: /commands/rclone_config/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/ and as part of making a release run "make commanddocs"
---
## rclone config

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_create.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config create"
slug: rclone_config_create
url: /commands/rclone_config_create/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/create/ and as part of making a release run "make commanddocs"
---
## rclone config create

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_delete.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config delete"
slug: rclone_config_delete
url: /commands/rclone_config_delete/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/delete/ and as part of making a release run "make commanddocs"
---
## rclone config delete

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_disconnect.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config disconnect"
slug: rclone_config_disconnect
url: /commands/rclone_config_disconnect/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/disconnect/ and as part of making a release run "make commanddocs"
---
## rclone config disconnect

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_dump.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config dump"
slug: rclone_config_dump
url: /commands/rclone_config_dump/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/dump/ and as part of making a release run "make commanddocs"
---
## rclone config dump

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_edit.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config edit"
slug: rclone_config_edit
url: /commands/rclone_config_edit/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/edit/ and as part of making a release run "make commanddocs"
---
## rclone config edit

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_file.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config file"
slug: rclone_config_file
url: /commands/rclone_config_file/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/file/ and as part of making a release run "make commanddocs"
---
## rclone config file

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_password.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config password"
slug: rclone_config_password
url: /commands/rclone_config_password/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/password/ and as part of making a release run "make commanddocs"
---
## rclone config password

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_providers.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config providers"
slug: rclone_config_providers
url: /commands/rclone_config_providers/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/providers/ and as part of making a release run "make commanddocs"
---
## rclone config providers

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_reconnect.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config reconnect"
slug: rclone_config_reconnect
url: /commands/rclone_config_reconnect/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/reconnect/ and as part of making a release run "make commanddocs"
---
## rclone config reconnect

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_show.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config show"
slug: rclone_config_show
url: /commands/rclone_config_show/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/show/ and as part of making a release run "make commanddocs"
---
## rclone config show

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_update.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config update"
slug: rclone_config_update
url: /commands/rclone_config_update/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/update/ and as part of making a release run "make commanddocs"
---
## rclone config update

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_config_userinfo.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone config userinfo"
slug: rclone_config_userinfo
url: /commands/rclone_config_userinfo/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/config/userinfo/ and as part of making a release run "make commanddocs"
---
## rclone config userinfo

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_copy.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone copy"
slug: rclone_copy
url: /commands/rclone_copy/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/copy/ and as part of making a release run "make commanddocs"
---
## rclone copy

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_copyto.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone copyto"
slug: rclone_copyto
url: /commands/rclone_copyto/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/copyto/ and as part of making a release run "make commanddocs"
---
## rclone copyto

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_copyurl.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone copyurl"
slug: rclone_copyurl
url: /commands/rclone_copyurl/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/copyurl/ and as part of making a release run "make commanddocs"
---
## rclone copyurl

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_cryptcheck.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone cryptcheck"
slug: rclone_cryptcheck
url: /commands/rclone_cryptcheck/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/cryptcheck/ and as part of making a release run "make commanddocs"
---
## rclone cryptcheck

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_cryptdecode.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone cryptdecode"
slug: rclone_cryptdecode
url: /commands/rclone_cryptdecode/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/cryptdecode/ and as part of making a release run "make commanddocs"
---
## rclone cryptdecode

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_dbhashsum.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone dbhashsum"
slug: rclone_dbhashsum
url: /commands/rclone_dbhashsum/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/dbhashsum/ and as part of making a release run "make commanddocs"
---
## rclone dbhashsum

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_dedupe.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone dedupe"
slug: rclone_dedupe
url: /commands/rclone_dedupe/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/dedupe/ and as part of making a release run "make commanddocs"
---
## rclone dedupe

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_delete.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone delete"
slug: rclone_delete
url: /commands/rclone_delete/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/delete/ and as part of making a release run "make commanddocs"
---
## rclone delete

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_deletefile.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone deletefile"
slug: rclone_deletefile
url: /commands/rclone_deletefile/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/deletefile/ and as part of making a release run "make commanddocs"
---
## rclone deletefile

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_genautocomplete.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone genautocomplete"
slug: rclone_genautocomplete
url: /commands/rclone_genautocomplete/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/genautocomplete/ and as part of making a release run "make commanddocs"
---
## rclone genautocomplete

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_genautocomplete_bash.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone genautocomplete bash"
slug: rclone_genautocomplete_bash
url: /commands/rclone_genautocomplete_bash/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/genautocomplete/bash/ and as part of making a release run "make commanddocs"
---
## rclone genautocomplete bash

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_genautocomplete_zsh.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone genautocomplete zsh"
slug: rclone_genautocomplete_zsh
url: /commands/rclone_genautocomplete_zsh/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/genautocomplete/zsh/ and as part of making a release run "make commanddocs"
---
## rclone genautocomplete zsh

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_gendocs.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone gendocs"
slug: rclone_gendocs
url: /commands/rclone_gendocs/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/gendocs/ and as part of making a release run "make commanddocs"
---
## rclone gendocs

Expand Down
3 changes: 2 additions & 1 deletion docs/content/commands/rclone_hashsum.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
date: 2020-02-01T10:26:53Z
date: 2020-02-10T12:28:36Z
title: "rclone hashsum"
slug: rclone_hashsum
url: /commands/rclone_hashsum/
# autogenerated - DO NOT EDIT, instead edit the source code in cmd/hashsum/ and as part of making a release run "make commanddocs"
---
## rclone hashsum

Expand Down
Loading

0 comments on commit dfb710e

Please sign in to comment.