第一個(gè)有個(gè)叫deepin的團(tuán)隊(duì)也自己造個(gè)輪子,專門用了自動(dòng)bind工具去將go bind到最新的gtk上,兒網(wǎng)上其他形形色色的gogtk差不多都是手動(dòng)綁定。
在淮上等地區(qū),都構(gòu)建了全面的區(qū)域性戰(zhàn)略布局,加強(qiáng)發(fā)展的系統(tǒng)性、市場(chǎng)前瞻性、產(chǎn)品創(chuàng)新能力,以專注、極致的服務(wù)理念,為客戶提供成都做網(wǎng)站、成都網(wǎng)站設(shè)計(jì)、成都外貿(mào)網(wǎng)站建設(shè) 網(wǎng)站設(shè)計(jì)制作按需求定制設(shè)計(jì),公司網(wǎng)站建設(shè),企業(yè)網(wǎng)站建設(shè),成都品牌網(wǎng)站建設(shè),營銷型網(wǎng)站,外貿(mào)營銷網(wǎng)站建設(shè),淮上網(wǎng)站建設(shè)費(fèi)用合理。
當(dāng)然也有相關(guān)的項(xiàng)目叫l(wèi)inuxdeepin,簡(jiǎn)直是金光閃閃。
第二個(gè)有個(gè)出名的項(xiàng)目叫做liteide(goqt),goqml也有個(gè)知名度還差不多的項(xiàng)目limetext,就是go寫的sublime的開源版本。
第三個(gè)有一個(gè)唯一的好處:原生。但是壞處就是不好用,甚至算不上能用,官方的例子都不多(就兩三個(gè)),目前我沒看到有比較出名使用它構(gòu)建的項(xiàng)目。
1、編譯vimgdb
下載vimgdb73和vim73
mkdir -p ./tmp
cd tmp
tar zxvf ../vim-7.3.tar.gz
unzip ../vimgdb-for-vim7.3-master.zip
mv vimgdb-for-vim7.3-master vimgdb-for-vim7.3
patch -p0 vimgdb-for-vim7.3/vim73.patch
cd vim73
安裝依賴
sudo apt-get install build-essential
sudo apt-get build-dep vim-gtk
sudo apt-get install libncurses5-dev
安裝
// 這里直接執(zhí)行make的操作
make
sudo make install
安裝vimgdb runtime
cd ../vimgdb-for-vim7.3
cp vimgdb_runtime ~/.vim/bundle
打開vim
:helptags ~/.vim/bundle/vimgdb_runtime/doc " 生成doc文件
添加配置.vimrc
" vimgdb插件
run macros/gdb_mappings.vim
在vim中執(zhí)行g(shù)db時(shí),報(bào) “Unable to read from GDB pseudo tty” 的錯(cuò)誤,因?yàn)闆]有安裝 gdb ,所以安裝gdb
sudo apt-get install gdb
2、安裝vundle
set up vundle
$ git clone ~/.vim/bundle/vundle
Configure Plugins
在.vimrc文件的開頭添加下面的內(nèi)容,有些不是必須的,可以注掉
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" alternatively, pass a path where Vundle should install plugins
"let path = '~/some/path/here'
"call vundle#rc(path)
" let Vundle manage Vundle, required
Plugin 'gmarik/vundle'
" The following are examples of different formats supported.
" Keep Plugin commands between here and filetype plugin indent on.
" scripts on GitHub repos
Plugin 'tpope/vim-fugitive'
Plugin 'Lokaltog/vim-easymotion'
Plugin 'tpope/vim-rails.git'
" The sparkup vim script is in a subdirectory of this repo called vim.
" Pass the path to set the runtimepath properly.
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
" scripts from
Plugin 'L9'
Plugin 'FuzzyFinder'
" scripts not on GitHub
Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
Plugin ''
" ...
filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" : PluginList - list configured plugins
" : PluginInstall(!) - install (update) plugins
" : PluginSearch(!) foo - search (or refresh cache first) for foo
" : PluginClean(!) - confirm (or auto-approve) removal of unused plugins
"
" see :h vundle for more details or wiki for FAQ
" NOTE: comments after Plugin commands are not allowed.
" Put your stuff after this line
Install Plugins
Launch vim and run
: PluginInstall
vim +PluginInstall +qall
3、官方vim-lang插件
Config vim file .vimrc,Add content bellow in bottom of the file
" 官方的插件
" Some Linux distributions set filetype in /etc/vimrc.
" Clear filetype flags before changing runtimepath to force Vim to
" reload them.
filetype off
filetype plugin indent off
set runtimepath+=$GOROOT/misc/vim
filetype plugin indent on
syntax on
autocmd FileType go autocmd BufWritePre Fmt
4、代碼補(bǔ)全的插件gocode
配置go的環(huán)境變量,比如我的配置,GOPATH變量是必須要配置的,PATH中必須把GOPATH的bin也添加進(jìn)去,否則沒有自動(dòng)提示,會(huì)提示找不到模式
export GOROOT=/usr/local/go
export GOPATH=/data/app/gopath
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin
Set up gocode
Then you need to get the appropriate version of the gocode, for 6g/8g/5g compiler you can do this:
go get -u github.com/nsf/gocode (-u flag for "update")
Configure vim in .vimrc file
Plugin 'nsf/gocode', {'rtp': 'vim/'}
Install Plugins
Launch vim and run
: PluginInstall
vim +PluginInstall +qall
寫一個(gè)helloword程序,輸入fmt后按C-xC-o如果能看到函數(shù)的聲明展示出來,說明安裝是正確的。
4、代碼跳轉(zhuǎn)提示godef
Set up godef
go get -v code.google.com/p/rog-go/exp/cmd/godef
go install -v code.google.com/p/rog-go/exp/cmd/godef
git clone ~/.vim/bundle/vim-godef
Configure vim in .vimrc file
Bundle 'dgryski/vim-godef'
Install Plugins
Launch vim and run
: PluginInstall
vim +PluginInstall +qall
5、代碼結(jié)構(gòu)提示gotags
Set up gotags
go get -u github.com/jstemmer/gotags
Put the following configuration in your vimrc:
Bundle 'majutsushi/tagbar'
nmap :TagbarToggle
let g:tagbar_type_go = {
\ 'ctagstype' : 'go',
\ 'kinds' : [
\ 'p:package',
\ 'i:imports:1',
\ 'c:constants',
\ 'v:variables',
\ 't:types',
\ 'n:interfaces',
\ 'w:fields',
\ 'e:embedded',
\ 'm:methods',
\ 'r:constructor',
\ 'f:functions'
\ ],
\ 'sro' : '.',
\ 'kind2scope' : {
\ 't' : 'ctype',
\ 'n' : 'ntype'
\ },
\ 'scope2kind' : {
\ 'ctype' : 't',
\ 'ntype' : 'n'
\ },
\ 'ctagsbin' : 'gotags',
\ 'ctagsargs' : '-sort -silent'
\ }
命令模式下按在右邊就會(huì)顯示當(dāng)前文件下的函數(shù)名,結(jié)構(gòu)體名等等,光標(biāo)放到相應(yīng)的tag上,按回車可以快速跳到程序中的相應(yīng)位置。
再次按會(huì)關(guān)閉tag窗口。
PS:本地的.vimrc的配置
" 插件管理器 vundle
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" alternatively, pass a path where Vundle should install plugins
"let path = '~/some/path/here'
"call vundle#rc(path)
" let Vundle manage Vundle, required
Plugin 'gmarik/vundle'
" The following are examples of different formats supported.
" Keep Plugin commands between here and filetype plugin indent on.
" scripts on GitHub repos
" Plugin 'tpope/vim-fugitive'
" Plugin 'Lokaltog/vim-easymotion'
" Plugin 'tpope/vim-rails.git'
" The sparkup vim script is in a subdirectory of this repo called vim.
" Pass the path to set the runtimepath properly.
" Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
" scripts from
" Plugin 'L9'
" Plugin 'FuzzyFinder'
" scripts not on GitHub
" Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
" Plugin ''
" ...
"
filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
" filetype plugin on
"
" Brief help
" : PluginList - list configured plugins
" : PluginInstall(!) - install (update) plugins
" : PluginSearch(!) foo - search (or refresh cache first) for foo
" : PluginClean(!) - confirm (or auto-approve) removal of unused plugins
"
" see :h vundle for more details or wiki for FAQ
" NOTE: comments after Plugin commands are not allowed.
" Put your stuff after this line
syntax on
" ********************************************************************
" 這里省略了其它不相關(guān)的插件
" vimgdb插件
run macros/gdb_mappings.vim
" 官方的插件
" Some Linux distributions set filetype in /etc/vimrc.
" Clear filetype flags before changing runtimepath to force Vim to
" reload them.
filetype off
filetype plugin indent off
set runtimepath+=$GOROOT/misc/vim
filetype plugin indent on
syntax on
autocmd FileType go autocmd BufWritePre buffer Fmt
" 代碼補(bǔ)全的插件
Bundle 'Blackrush/vim-gocode'
" 代碼跳轉(zhuǎn)提示
Bundle 'dgryski/vim-godef'
" 代碼結(jié)構(gòu)提示
Bundle 'majutsushi/tagbar'
nmap F8 :TagbarToggleCR
let g:tagbar_type_go = {
\ 'ctagstype' : 'go',
\ 'kinds' : [
\ 'p:package',
\ 'i:imports:1',
\ 'c:constants',
\ 'v:variables',
\ 't:types',
\ 'n:interfaces',
\ 'w:fields',
\ 'e:embedded',
\ 'm:methods',
\ 'r:constructor',
\ 'f:functions'
\ ],
\ 'sro' : '.',
\ 'kind2scope' : {
\ 't' : 'ctype',
\ 'n' : 'ntype'
\ },
\ 'scope2kind' : {
\ 'ctype' : 't',
\ 'ntype' : 'n'
\ },
\ 'ctagsbin' : 'gotags',
\ 'ctagsargs' : '-sort -silent'
\ }
或特別的跟系統(tǒng)相關(guān)不大的,可以考慮用C++;
在動(dòng)態(tài)網(wǎng)頁上還可以用perl、python、java之類的;
一般系統(tǒng)管理員和普通用戶,用的最多的恐怕就是bash了,shell可以完成一系列動(dòng)作和自動(dòng)化管理。當(dāng)然,這里也可以用perl或python之類的腳本語言
由此看來,在linux里編程:
1. 接近系統(tǒng)的軟件開發(fā)必然是C;
2. 系統(tǒng)關(guān)聯(lián)不大的應(yīng)用程序開發(fā)可以用C或C++;
3. 動(dòng)態(tài)網(wǎng)頁方面可以用perl或python腳本語言或java;
4. 日常管理上,當(dāng)然是bash!
5. 做GUI界面開發(fā)的話,很多人用GTK,也有很多人用Qt;
因此,說C是linux編程的主流一點(diǎn)都不過分。這也是linux這個(gè)開源環(huán)境和本身機(jī)制所導(dǎo)致的,就連linus都力挺C,而駁斥C++。雖然沒必要拒絕C++,但是,不可否認(rèn),C更適合linux~
另外,虛機(jī)團(tuán)上產(chǎn)品團(tuán)購,超級(jí)便宜
蘋果公司允許開發(fā)人員使用 Objective-C 和 Swift 兩種編程語言開發(fā) iOS 應(yīng)用,因?yàn)檫@兩種語言已經(jīng)緊密地與蘋果的開發(fā)環(huán)境和工具集整合在一起。
安卓操作系統(tǒng)原生支持 Java 語言,因此它是安卓應(yīng)用開發(fā)的首選語言。但是,安卓也支持使用其他語言(如 Kotlin)來開發(fā)應(yīng)用,并且使用其他語言的開發(fā)人員可以通過 Java Native Interface (JNI) 訪問安卓的底層系統(tǒng) API。
Go語言不是安卓操作系統(tǒng)原生支持的語言,因此需要使用其他方法才能在安卓上開發(fā) Go 語言應(yīng)用。
具體的方法有:
gomobile: Go 語言官方支持的工具,用于在安卓和 iOS 上編譯 Go 代碼為本地應(yīng)用。
go-android: 一個(gè)開源庫,用于在安卓上運(yùn)行 Go 語言代碼。
go-gtk: 一個(gè)庫,用于在安卓上使用 GTK+ 構(gòu)建 GUI 應(yīng)用。
這些項(xiàng)目允許開發(fā)人員在安卓上使用 Go 語言開發(fā)應(yīng)用,但請(qǐng)注意,目前這些項(xiàng)目可能仍然處于試驗(yàn)階段,不保證穩(wěn)定性和性能。
1)腳本類的,大約有十來種,比DOS中的批命令和WINDOWS中的CMD強(qiáng)多了,比較簡(jiǎn)單,許多小工具程序都是用它寫的,一般用戶也應(yīng)該學(xué)一些,可以解決許多日常的問題,以及一些比較輕量級(jí)的程序問題,這類語言又稱SHELL,舉例:BASH。后來又有許多更復(fù)雜、功能更強(qiáng)的腳本語言,例如PERL,JAVA等。
2)正規(guī)的編程語言:C/C++、匯編語言等。許多主要的比較復(fù)雜的程序還都是用它們?cè)O(shè)計(jì)的。包括核心系統(tǒng)本身。
3)專用的語言,LINUX中有一個(gè)X視窗,它們有一些比較專用的設(shè)計(jì)語言,各個(gè)不同體系還度有些區(qū)別,它主要是用于設(shè)計(jì)在X窗口中的程序,QT、GTK+……等等
如果只允許選擇一種語言,那應(yīng)該還是C/C++,許多其它語言都同它有一些關(guān)系。
不過這種說法是有前提的,學(xué)好JAVA也許也很有用。它的應(yīng)用范圍足夠大了。
標(biāo)題名稱:gtkgo語言 gts語言
本文URL:http://chinadenli.net/article20/dodcdjo.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供小程序開發(fā)、網(wǎng)頁設(shè)計(jì)公司、品牌網(wǎng)站制作、網(wǎng)站維護(hù)、電子商務(wù)、企業(yè)網(wǎng)站制作
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請(qǐng)盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如需處理請(qǐng)聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來源: 創(chuàng)新互聯(lián)