@@ -23,17 +23,17 @@ local function execute(...)
23
23
end
24
24
end
25
25
26
- local changed = false
27
- for name , patchspec in pairs (patched ) do
26
+ local hasChanged = false
27
+ for name , patchS in pairs (patched ) do
28
28
local dir = fs .combine (patchDirectory , " rocks-original/" .. name )
29
29
if force or not fs .isDir (dir ) then
30
- changed = true
30
+ hasChanged = true
31
31
log (" Fetching " .. name )
32
32
33
33
fs .delete (dir )
34
34
35
- local version = patchspec .version
36
- if not patchspec .version then
35
+ local version = patchS .version
36
+ if not patchS .version then
37
37
error (" Patchspec" .. name .. " has no version" , 0 )
38
38
end
39
39
@@ -42,12 +42,12 @@ local function execute(...)
42
42
error (" Cannot find '" .. name .. " '" , 0 )
43
43
end
44
44
45
- local rock = rockspec .fetchRockspec (manifest .server , name , patchspec .version )
45
+ local rock = rockspec .fetchRockspec (manifest .server , name , patchS .version )
46
46
47
47
local files = rockspec .extractFiles (rock )
48
48
if # files == 0 then error (" No files for " .. name .. " -" .. version , 0 ) end
49
49
50
- local downloaded = download (rock . source , files )
50
+ local downloaded = download (patchspec . extractSource ( rock , patchS ) , files )
51
51
52
52
if not downloaded then error (" Cannot find downloader for " .. rock .source .url , 0 ) end
53
53
@@ -59,7 +59,7 @@ local function execute(...)
59
59
end
60
60
end
61
61
62
- if not changed then
62
+ if not hasChanged then
63
63
error (" No packages to fetch" , 0 )
64
64
end
65
65
0 commit comments