Skip to content
Snippets Groups Projects
Select Git revision
  • a8ab35cf6bca183c09819becadc2e7ab9e5f19ce
  • release default
  • 11-22-implement-kv-interface-defined-in-collectiveversionedkvgo
  • master protected
  • XX-4688/DbEncoding
  • hotfix/update
  • @XX-4682/Files
  • hotfix/XX-4655
  • dev protected
  • project/HavenNotifications
  • XX-4602/SilentMessageType
  • jono/npmTest
  • wasmTest2
  • XX-4461/FileUpload
  • XX-4505/blockuser
  • XX-4441
  • Jakub/Emoji-CI-Test
  • testing/websockets
  • fastReg
  • fast-registration
  • NewHostPool
  • v0.3.22
  • v0.3.21
  • v0.3.20
  • v0.3.18
  • v0.3.17
  • v0.3.16
  • v0.3.15
  • v0.3.14
  • v0.3.13
  • v0.3.12
  • v0.3.11
  • v0.3.10
  • v0.3.9
  • v0.3.8
  • v0.3.7
  • v0.3.6
  • v0.3.5
  • v0.3.4
  • 812b395df518ce096d01d5292596ca26f8fe92d9c4487ddfa515e190a51aa1a1
  • 76ba08e2dfa1798412a265404fa271840b52c035869111fce8e8cdb23a036a5a
41 results

wasm_exec.js

Blame
  • version.go 1.58 KiB
    ///////////////////////////////////////////////////////////////////////////////
    // Copyright © 2020 xx network SEZC                                          //
    //                                                                           //
    // Use of this source code is governed by a license that can be found in the //
    // LICENSE file                                                              //
    ///////////////////////////////////////////////////////////////////////////////
    
    // Handles command-line version functionality
    
    package cmd
    
    import (
    	"fmt"
    
    	"github.com/spf13/cobra"
    	"gitlab.com/elixxir/client/api"
    	"gitlab.com/xx_network/primitives/utils"
    )
    
    // Change this value to set the version for this build
    const currentVersion = "4.0.0"
    
    func Version() string {
    	out := fmt.Sprintf("Elixxir Client v%s -- %s\n\n", api.SEMVER,
    		api.GITVERSION)
    	out += fmt.Sprintf("Dependencies:\n\n%s\n", api.DEPENDENCIES)
    	return out
    }
    
    func init() {
    	rootCmd.AddCommand(versionCmd)
    	rootCmd.AddCommand(generateCmd)
    }
    
    var versionCmd = &cobra.Command{
    	Use:   "version",
    	Short: "Print the version and dependency information for the Elixxir binary",
    	Long:  `Print the version and dependency information for the Elixxir binary`,
    	Run: func(cmd *cobra.Command, args []string) {
    		fmt.Printf(Version())
    	},
    }
    
    var generateCmd = &cobra.Command{
    	Use:   "generate",
    	Short: "Generates version and dependency information for the Elixxir binary",
    	Long:  `Generates version and dependency information for the Elixxir binary`,
    	Run: func(cmd *cobra.Command, args []string) {
    		utils.GenerateVersionFile(currentVersion)
    	},
    }