Go 01 安裝 Go開發的工具

2022-07-02 03:45:11 字數 578 閱讀 7430

vscode (微軟的產品)

上傳.tar.gz 安裝包通過 xftp5 上傳到linux系統上;

通過 tar  -zxvf  …..tar.gz   解壓

然後 cd  到解壓後的資料夾下,會有乙個code的資料夾, 接著執行  ./code 執行即可啟動vscode的軟體;

mac 本身系統是安裝好ssh服務的,但是沒有啟動

檢視是否啟動ssh服務指令:

sudo  launchctl  list  | grep ssh

停止ssh服務指令:

sudo  launchctl unload  -w /s/…..ssh.plist

啟動ssh服務指令:

sudo  launchctl  load  -w  /s/……ssh.plist

解壓.zip檔案

雙擊開啟 然後點選左上角的檔案的圖示 接著 點選 open folder(即開啟資料夾可以提前建立 gocode)

接著 建立 go檔案開始寫**

有了工具可以寫go**,但是需要 把go** 編譯和執行 跑起來,即需要搭建go的開發環境 

有些省略的地方可以自行查詢

Go 01 常量與變數使用注意事項

go是靜態型別,不能在執行期改變變數的型別。面試題關於全域性變數的初始化,下面正確的使用方式是 a var i int 10 b var i 10 c i 10這是乙個關於go語言全域性變數宣告和賦值的考察,go語言中的變數宣告使用關鍵字var,例如 var str string 宣告變數 str ...

go開發工具goclipse的安裝

start eclipse,go to help install new software.click the add.button,then enter the update site url in the location field,click ok.select the goclipse f...

Go 安裝Go語言及搭建Go語言開發環境

tar c usr local xzf go1.15.6.linux amd64.tar.gzvim etc profile在profile中新增go的環境變數,新增完成後可通過.etc.profile 讓配置檔案立即生效。和 之間有空格 go export go home usr local go...