🎨 inject version code
This commit is contained in:
		
							parent
							
								
									cf99c5f145
								
							
						
					
					
						commit
						e0a26267bd
					
				@ -60,6 +60,9 @@ func doSelfUpdate() {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func main() {
 | 
					func main() {
 | 
				
			||||||
 | 
						// 来自于 GoReleaser 的版本号
 | 
				
			||||||
 | 
						dao.Version = version
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	rootCmd.PersistentFlags().StringVarP(&server, "server", "s", "localhost:5555", "客户端ID")
 | 
						rootCmd.PersistentFlags().StringVarP(&server, "server", "s", "localhost:5555", "客户端ID")
 | 
				
			||||||
	rootCmd.PersistentFlags().StringVarP(&clientID, "id", "i", "", "客户端ID")
 | 
						rootCmd.PersistentFlags().StringVarP(&clientID, "id", "i", "", "客户端ID")
 | 
				
			||||||
	rootCmd.PersistentFlags().StringVarP(&clientSecret, "secret", "p", "", "客户端Secret")
 | 
						rootCmd.PersistentFlags().StringVarP(&clientSecret, "secret", "p", "", "客户端Secret")
 | 
				
			||||||
 | 
				
			|||||||
@ -234,7 +234,7 @@ modify_dashboard_config() {
 | 
				
			|||||||
        return 0
 | 
					        return 0
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    echo "关于管理员 GitHub ID:复制自己GitHub头像图片地址,/[ID].png 多个用英文逗号隔开 id1,id2,id3" &&
 | 
					    echo "关于管理员 GitHub ID:复制自己GitHub头像图片地址里面的数字,/87123.png 多个用英文逗号隔开 87123,id2,id3" &&
 | 
				
			||||||
        read -p "请输入 ID 列表: " nz_admin_ids &&
 | 
					        read -p "请输入 ID 列表: " nz_admin_ids &&
 | 
				
			||||||
        echo "关于 GitHub Oauth2 应用:在 https://github.com/settings/developers 创建,无需审核 Callback 填 http(s)://域名或IP/oauth2/callback" &&
 | 
					        echo "关于 GitHub Oauth2 应用:在 https://github.com/settings/developers 创建,无需审核 Callback 填 http(s)://域名或IP/oauth2/callback" &&
 | 
				
			||||||
        read -p "请输入 GitHub Oauth2 应用的 Client ID: " nz_github_oauth_client_id &&
 | 
					        read -p "请输入 GitHub Oauth2 应用的 Client ID: " nz_github_oauth_client_id &&
 | 
				
			||||||
@ -262,6 +262,7 @@ modify_dashboard_config() {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
restart_dashboard() {
 | 
					restart_dashboard() {
 | 
				
			||||||
    cd $NZ_DASHBOARD_PATH
 | 
					    cd $NZ_DASHBOARD_PATH
 | 
				
			||||||
 | 
					    docker-compose pull
 | 
				
			||||||
    docker-compose down
 | 
					    docker-compose down
 | 
				
			||||||
    docker-compose up -d
 | 
					    docker-compose up -d
 | 
				
			||||||
    if [[ $? == 0 ]]; then
 | 
					    if [[ $? == 0 ]]; then
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user