顯示具有 git 標籤的文章。 顯示所有文章
顯示具有 git 標籤的文章。 顯示所有文章

2021年1月7日 星期四

git repo 管理

 git repo 管理





有一個使用情形是用 repo管理

 

已經出一版 1.0 sdk了。


如果是有patch的話想只出1.01有修改的檔案

如  project a 的 ddd.c  和 project b的 eee.c

 

是不是有對應的指令可以做到


repo forall -c 'git diff --src-prefix=old/$REPO_PATH/ --dst-prefix=new/$REPO_PATH/ v1.0 v1.0.1' > all.patch


This command generates a single patch for the change from v1.0 to v1.0.1 tags.




將有修改後的檔案 tar起來。


single tar file::  files the change from v1.0 to v1.0.1 tags.



List file different to `filelist`

$ repo forall -c 'git diff HEAD v1.0.1 v1.0 --name-only | sed -e "s|^|$REPO_PATH/|"' > filelist


Create tarball according to `filelist`

$ tar jcvf test.tar.bz2 `cat filelist`





https://stackoverflow.com/questions/33030289/is-there-a-tool-to-create-repo-manifest-file-with-sha-based-on-current-work-dire




The repo manifest command creates manifest files with fixed SHA-1s based on the current workspace.


repo manifest -r -o my-manifest.xml







只用git管理的情形

http://stackoverflow.com/questions/12841360/git-archive-from-changed-files-on-bare-repos

 


git archive --format=tar --prefix='/' master `git diff V1.02 master --name-only` | gzip -9 > ~/tars/update-v1.02-`git describe master --tags`.tar.gz



https://www.jianshu.com/p/58e5d4f9f9a9


https://source.android.com/setup/develop/repo



大丈夫日記 

http://ryan0210.blogspot.com/2013/10/coding-repo-git.html


泰勞筆記

https://thai-lin.blogspot.com/2017/05/repo-git.html




repo sync -j threadcount



 -j threadcount :在線程之間拆分同步,以加快完成速度。確保不要通過為其他任務保留一些CPU來壓倒計算機。要查看可用CPU的數量,請首先運行: nproc --all

 



git push origin master 


1.

直接 push:

$ git push orgin default:master


2.


進到 code review的push 指令

git push origin default:refs/for/master


PS. 其實 repo upload 指令,就是把 topic branch push 到 refs/for/project-branch,

       就會直接進到 code-review 頁面上



tig


m main view

d diff view

r branch view the branches, remotes and tags in the repository.

t tree view

b blame view Displays the file content annotated or blamed by commits.


all view

j k up/down

J K next/previous

上鍵 下鍵 next/previous

page up/down : page up down

q 關閉 畫面


in main view

D 切換 date display modes

A 切換 author display modes

X 切換 commit sha

enter  查看 commit 的詳細 diff 變更 

q 關閉 diff 畫面。


還有 tig 指令後面接 branch 名稱可以直接查看分支,接著在分支 commit 上按大寫 C 可以 cherry-pick 回目前的 branch,而 tig 後面接檔名的話可以直接查看跟這個檔案有關的 commit,更多的基本功能介紹可以看 git? tig! 這篇文章。



https://devhints.io/tig

http://blog.kidwm.net/388

http://jonas.nitro.dk/tig/manual.html


2017年12月1日 星期五

debian 9 build code notes embedded linux openwrt





sudo dpkg-reconfigure dash
選擇 No 把 dash 關掉再試試看


samba vim lib32z1 make build-essential gcc git libssl-dev lrzsz
libncurses5-dbg libncurses5-dev libncursesw5-dbg libncursesw5-dev
bison flex iperf3 tmux ctags openssh-server openssh-sftp-server



aptitude install libc6-i386 libc6-dev-i386

aptitude install zlib1g-i386


dash / bash
http://www.jianshu.com/p/762d4cccee7e

https://www.ubuntu-tw.org/modules/newbb/viewtopic.php?post_id=23963

---------------------------
openssh server

/etc/ssh/sshd_config


UseDNS no


# Ciphers and keying
#RekeyLimit default none
Ciphers aes128-cbc
MACs hmac-md5-96,hmac-sha1-96

----------
linux crc32 計算

cksfv

apt-get install cksfv

example

cksfv fpga_test_newmpm.bin


; Generated by cksfv v1.3.14 on 2017-12-18 at 15:46.58
; Project web site: http://www.iki.fi/shd/foss/cksfv/
;
;        22516  15:50.29 2017-02-07 fpga_test_newmpm.bin
fpga_test_newmpm.bin 9E9268D9


2016年3月30日 星期三

linux command/tool

cksum

comm

csplit

cut

md5sum

nl

nohup

od

sum

tee

tree

edquota

quota on

cmp

diff

diffstat

badblocks

eject

whereis

sync

contrab

unmask

dialgo --timebox "time" 8 30

2015年11月19日 星期四

miniasp blog short link



擷取整個網頁變成一張圖
http://blog.miniasp.com/post/2007/12/24/Useful-tools-URL2JPEG.aspx

介紹好用工具:grepWin
http://blog.miniasp.com/post/2008/01/30/Useful-tool-grepWin.aspx

Sublime Text 3 新手上路:必要的安裝、設定與基本使用教學
http://blog.miniasp.com/post/2014/01/07/Useful-tool-Sublime-Text-3-Quick-Start.aspx

如何在 Windows 下透過 sshfs 掛載遠端目錄
http://blog.miniasp.com/post/2013/11/30/Useful-tool-SSHFS-SSH-Filesystem.aspx


如何利用 md5sum 稽核重要檔案與驗證檔案完整性
http://blog.miniasp.com/post/2009/07/07/Useful-tools-md5sum-md5deep-md5summer-to-verify-files.aspx

Bullzip PDF Printer (列印文件成PDF或圖檔)
http://blog.miniasp.com/post/2009/04/04/Useful-tools-Bullzip-PDF-Printer.aspx

介紹好用工具:tree (以圖形顯示磁碟機或路徑的資料夾架構)
http://blog.miniasp.com/post/2010/02/02/Useful-tools-Tree-for-Windows.aspx

介紹好用工具:Imagine ( 支援 Unicode 的看圖軟體 )
http://blog.miniasp.com/post/2009/03/30/Useful-tools-Imagine.aspx

介紹好用工具:KeePass Password Safe
http://blog.miniasp.com/post/2008/09/03/Useful-tool-KeePass-Password-Safe.aspx

開發人員工具軟體清單 ( Windows 7 Ultimate )
http://blog.miniasp.com/post/2009/08/14/Will-2009-Ultimate-Developer-Software-List.aspx

開發人員工具軟體清單 ( 最新 2011 年版 )
http://blog.miniasp.com/post/2011/02/26/Will-2011-Ultimate-Developer-Tool-Software-List.aspx

開發人員工具軟體清單 ( 最新 2013 年版 )
http://blog.miniasp.com/post/2013/05/02/Will-2013-Ultimate-Developer-Tool-Software-List.aspx


使用 sed 工具在 Linux 環境下快速完成「搜尋取代」的任務
http://blog.miniasp.com/post/2010/12/25/Useful-tool-Find-and-Replace-with-sed-command.aspx

如何讓 Git 僅匯出在特定版本中新增或修改過的檔案
http://blog.miniasp.com/post/2014/04/02/Git-Export-Only-Added-Modified-Files.aspx

如何查詢 Linux 的種類與版本 ( Linux Standard Base )
http://blog.miniasp.com/post/2009/02/25/How-to-query-Linux-distribution-and-version-information.aspx

Linux 備份/還原筆記(支援甲機備份,乙機還原)
http://blog.miniasp.com/post/2008/09/12/Will-Linux-Backup-Restore-Notes.aspx

免費電子書:Ubuntu Pocket Guide and Reference
http://blog.miniasp.com/post/2009/01/31/Free-E-Book-Ubuntu-Pocket-Guide-and-Reference.aspx

品質來自對細節的講究
http://blog.miniasp.com/post/2009/05/27/Quality-is-comes-from-fastidious-about-details.aspx

從團隊中學習合作精神
http://blog.miniasp.com/post/2007/11/06/Learning-how-to-cooperation-in-a-team.aspx

的軟體哲學
http://blog.miniasp.com/post/2008/02/28/The-Software-Philosophy-from-Will.aspx


回味三年前寫的文章: 我的工作心得與觀察 (軟體)
http://blog.miniasp.com/post/2007/11/27/My-working-notes-and-observation-3-years-ago.aspx

邁向成功的 8 個秘密 ( by Richard St. John )
http://blog.miniasp.com/post/2009/05/31/TED-Talks-Richard-St-John-8-secrets-of-success.aspx

該做的事千萬不要遲疑,馬上行動!(備份與還原)
http://blog.miniasp.com/post/2008/06/07/Important-Backup-and-Restore-dont-hesitate.aspx



分享幾個學習英文聽力的絕招
http://blog.miniasp.com/post/2008/11/04/Share-some-English-learning-tips.aspx