diff options
author | LJea <cnljea@outlook.com> | 2022-10-22 21:07:52 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-22 20:07:52 +0800 |
commit | fd5874b07b73687f90e8cb7b171b67457364ebe9 (patch) | |
tree | 004f973c12244b8ddd7146448198a27311f0b9d4 | |
parent | ce25881c880d9711f211be05f92a809304a436e3 (diff) |
ui: add usage instructions for PAT (#7194)
Co-authored-by: Joe Chen <jc@unknwon.io>
-rw-r--r-- | conf/locale/locale_en-US.ini | 1 | ||||
-rw-r--r-- | conf/locale/locale_ja-JP.ini | 2 | ||||
-rw-r--r-- | conf/locale/locale_zh-CN.ini | 4 | ||||
-rw-r--r-- | templates/user/settings/security.tmpl | 5 |
4 files changed, 7 insertions, 5 deletions
diff --git a/conf/locale/locale_en-US.ini b/conf/locale/locale_en-US.ini index c2eaa4df..e4cf3ddd 100644 --- a/conf/locale/locale_en-US.ini +++ b/conf/locale/locale_en-US.ini @@ -370,6 +370,7 @@ two_factor_disable_success = Two-factor authentication has disabled successfully manage_access_token = Manage Personal Access Tokens generate_new_token = Generate New Token tokens_desc = Tokens you have generated that can be used to access the Gogs APIs. +access_token_tips=The username you log into the Git app with is your personal access token. You can log in with an empty password or "x-access-token" as the password. new_token_desc = Each token will have full access to your account. token_name = Token Name generate_token = Generate Token diff --git a/conf/locale/locale_ja-JP.ini b/conf/locale/locale_ja-JP.ini index 9cfb942b..94024bb3 100644 --- a/conf/locale/locale_ja-JP.ini +++ b/conf/locale/locale_ja-JP.ini @@ -1175,7 +1175,7 @@ config.server_config=サーバーの構成 config.brand_name=ブランド名 config.run_user=実行ユーザー config.run_mode=実行モード -config.server.external_url=外部 URL +config.server.external_url=外部 URL config.server.domain=ドメイン config.server.protocol=プロトコル config.server.http_addr=HTTPアドレス diff --git a/conf/locale/locale_zh-CN.ini b/conf/locale/locale_zh-CN.ini index db5dce2c..33b5788b 100644 --- a/conf/locale/locale_zh-CN.ini +++ b/conf/locale/locale_zh-CN.ini @@ -634,7 +634,7 @@ pulls.nothing_merge_base=由于两个分支各自拥有完全不同的提交历 pulls.has_pull_request=`已经存在目标分支的合并请求:<a href="%[1]s/pulls/%[3]d">%[2]s#%[3]d</a>` pulls.create=创建合并请求 pulls.title_desc=请求将 %[1]d 次代码提交从 <code>%[2]s</code> 合并至 <code>%[3]s</code> -pulls.merged_title_desc=于 %[4]s 将 %[1]d 次代码提交从 <code>%[2]s</code>合并至 <code>%[3]s</code> +pulls.merged_title_desc=于 %[4]s 将 %[1]d 次代码提交从 <code>%[2]s</code>合并至 <code>%[3]s</code> pulls.tab_conversation=对话内容 pulls.tab_commits=代码提交 pulls.tab_files=文件变动 @@ -816,7 +816,7 @@ settings.githook_edit_desc=如果钩子未启动,则会显示样例文件中 settings.githook_name=钩子名称 settings.githook_content=钩子文本 settings.update_githook=更新钩子设置 -settings.add_webhook_desc=我们会通过 <code>POST</code> 请求将订阅事件信息发送至向指定 URL 地址。您可以设置不同的数据接收方式(JSON 或 <code>x-www-form-urlencoded</code>)。 请查阅 <a target="_blank" href="%s">Webhooks 文档</a> 获取更多信息。 +settings.add_webhook_desc=我们会通过 <code>POST</code> 请求将订阅事件信息发送至向指定 URL 地址。您可以设置不同的数据接收方式(JSON 或 <code>x-www-form-urlencoded</code>)。 请查阅 <a target="_blank" href="%s">Webhooks 文档</a> 获取更多信息。 settings.payload_url=推送地址 settings.content_type=数据格式 settings.secret=密钥文本 diff --git a/templates/user/settings/security.tmpl b/templates/user/settings/security.tmpl index f779b058..d14ed315 100644 --- a/templates/user/settings/security.tmpl +++ b/templates/user/settings/security.tmpl @@ -23,7 +23,8 @@ {{if .TwoFactor}} <br> <p>{{.i18n.Tr "settings.two_factor_view_recovery_codes" AppSubURL "/user/settings/security/two_factor_recovery_codes" | Safe}}</p> - <p>{{.i18n.Tr "settings.two_factor_http" AppSubURL "/user/settings/applications" "https://{token}@try.gogs.io/user/repo.git" | Safe}}</p> + <p>{{.i18n.Tr "settings.two_factor_http" AppSubURL "/user/settings/applications" "https://{token}:x-access-token@try.gogs.io/user/repo.git" | Safe}}</p> + <p>{{.i18n.Tr "settings.access_token_tips"}}</p> {{end}} </div> </div> @@ -49,4 +50,4 @@ </div> </div> </div> -{{template "base/footer" .}}
\ No newline at end of file +{{template "base/footer" .}} |