Skip to content

zhonghphuan/AutoCommit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

AutoCommit

Fastlane自动提交合并代码

平常在公司用git提交代码好几行命令,敲都敲吐了,用sourceTree工具切换提交也点吐了.就随手用fastlane写了一个自动化脚本,在自己分支一键提交后将代码合并到远程仓库再切回自己分支.

执行:fastlane doit fr:xx to:xx m:'xxxx'

效果:

命令拆解:

fastlane:执行fastlane命令

doit:自己命名的已编辑好由各个action组成的航道lane模块命令(主体脚本)

fr:参数(from缩写,从哪个分支)

to:参数(往哪个分支合并代码)

m:参数(描述)

示例:从自己dev分支往远程master分支提交合并代码,只需:fastlane doit fr:dev to:master m:’xxxx’

一.安装fastlane:

1.确保安装ruby:ruby -v

2.确保xcode-select安装:xcode-select --install

3.安装:sudo gem install fastlane

4.查看版本:fastlane --version

二.如何使用自动化提交代码脚本:

1.将脚本文件夹拖入到项目主目录下

2.在.gitignore添加

fastlane/report.xml

fastlane/Preview.html

fastlane/screenshots

fastlane/test_output

About

Fastlane自动提交合并代码

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages