Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support update script #438

Merged
merged 23 commits into from Jun 6, 2019

Conversation

@OpportunityLiu
Copy link
Contributor

commented Jun 3, 2019

Close #437

Using update with --scriptonly flag to update only lua script.

@OpportunityLiu OpportunityLiu force-pushed the OpportunityLiu:new-win-install branch from b0663b9 to 543a231 Jun 3, 2019

@OpportunityLiu OpportunityLiu force-pushed the OpportunityLiu:new-win-install branch from 63de0de to da6b384 Jun 4, 2019

xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved
xmake/actions/update/main.lua Outdated Show resolved Hide resolved

@OpportunityLiu OpportunityLiu force-pushed the OpportunityLiu:new-win-install branch from 2f757d4 to 2eeaac2 Jun 5, 2019

@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 5, 2019

好像可以了

@OpportunityLiu OpportunityLiu force-pushed the OpportunityLiu:new-win-install branch from fc2eef6 to 45b3634 Jun 5, 2019

xmake/scripts/update-script.sh Outdated Show resolved Hide resolved
@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

看着没啥问题了,等晚上我再测试下

@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

getpb.ps1是不是没用了

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

getpb.ps1是不是没用了

这个是之前有个老外贡献的,原本是配合 ci 构建,直接拉取安装构建好的exe包,不过后来一直没去用,就废弃了

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

我在xp下测了了,在xmake源码根目录执行:

$ xmake update --scriptonly dev

之后会弹个 console 框,覆盖原有的console界面,然后上面仅显示 Removing ... 等了好久,没啥其他提示,再等了好久 才成功,这个提示能改进下么。

这个倒还不是主要问题,关键是update完,我执行命令所在目录的 xmake 下 所有源码 都被删了 = =

@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

我写的覆盖目标是 os.programdir()

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

我写的覆盖目标是 os.programdir()

我重新试了下,xmake源码下的文件还是都被删了,只留下空文件夹,我再看看。

fix
@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

vprint("prepared to downlaod to temp dir %s ..", sourcedir)

这里有个typo,download

@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

之前的脚本,我发现每次CI要build两遍。。。
get.ps1 脚本里一遍,外面一遍

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

之前的脚本,我发现每次CI要build两遍。。。
get.ps1 脚本里一遍,外面一遍

get.ps1 里面那一遍应该是下载 xmake-dev.exe 版本然后编译出最新的dev分支core安装,保证安装的是dev上最新版本。。

之后的那一遍是用最新core源码编译安装的 exe bin 去做编译测试,对自身core进行自编译测试,完成新版本的自举测试

所以第一遍只用于安装,第二遍用于ci自举编译测试,之后再跑tests

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

我看了下,确实xp下会删掉当前目录文件

echo Removing old files in "%~1"
cd "%~1"
echo %CD%
pause
Removing old files in "C:\Program Files\xmake"
E:\personal\xmake
请按任意键继续. . .

似乎 cd "%~1" 没进去,当前目录没变,导致误删了

这个命令,只能在相同 drive下切换,跨盘符 cd 不生效

@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

get.ps1 里面那一遍应该是下载 xmake-dev.exe 版本然后编译出最新的dev分支core安装,保证安装的是dev上最新版本。。

之后的那一遍是用最新core源码编译安装的 exe bin 去做编译测试,对自身core进行自编译测试,完成新版本的自举测试

好像不是很有必要啊,只要第二遍能通过就说明没啥问题

似乎 cd "%~1" 没进去,当前目录没变,导致误删了

这就命中我的盲点了,只会用pwsh,bat语法我都是现搜的

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

这就命中我的盲点了,只会用pwsh,bat语法我都是现搜的

我看了下,加个 /d参数应该就可以了 cd /d "%~1"

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

好像不是很有必要啊,只要第二遍能通过就说明没啥问题

所以编译了core两遍了么,之后就开始跑tests了

OpportunityLiu added some commits Jun 6, 2019

fix
.appveyor.yml Show resolved Hide resolved
@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

好像xmake并没有用stderr?

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

好像xmake并没有用stderr?

恩,没有用

OpportunityLiu added some commits Jun 6, 2019

fix
@OpportunityLiu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 6, 2019

没啥问题,CI测试能跑过就merge吧

@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

我这边本机试了下,也没啥问题了。。

@waruqi waruqi merged commit 991e0e0 into xmake-io:dev Jun 6, 2019

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@waruqi

This comment has been minimized.

Copy link
Member

commented Jun 6, 2019

多谢。👍

@OpportunityLiu OpportunityLiu deleted the OpportunityLiu:new-win-install branch Jun 6, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.