-
Notifications
You must be signed in to change notification settings - Fork 27
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
love-release not packing everything in project directory #36
Comments
I have stumbled upon this once too, but I wasn't able to identify the causes of this error. I'll try to fix this. |
Would you please check the return value of I think it may stay in that directory for ever Also changing the current directory like that inside the loop may destroy the iterator Consider saving all the folder names and after the whole folder was iterated, iterate on the next one These are just suggestions not tested and not proved to work, but some ideas that may help debug this. Cheers |
Thanks for the suggestions :) Debug all the things ! |
Try something like this: local _buildFileTree
_buildFileTree = function(dir)
local subDirs = {}
for file in assert(fs.dir()) do
if not file:find("^%.git") then
if fs.is_dir(file) then
subDirs[#subDirs + 1] = file
elseif fs.is_file(file) then
dir[#dir+1] = file
end
end
end
for _, path in ipairs(subDirs) do
local newDir = {}
dir[path] = newDir
assert(fs.change_dir(path))
_buildFileTree(newDir)
assert(fs.pop_dir())
end
end This has the overhead of needing a secondary loop but will probably work more reliably. You have to consider that |
This issue was related to Lua not handling coroutines iterators right, the function being recursive generated multiple coroutine iterators and they didn't resume right. The solution is to make the first loop non-recursive and create a secondary loop where the recursive function is called.
This issue was related to Lua not handling coroutines iterators right, the function being recursive generated multiple coroutine iterators and they didn't resume right. The solution is to make the first loop non-recursive and create a secondary loop where the recursive function is called.
This should be fixed now 👍 |
For some reason, only my font folder, conf.lua, and my readme gets packed.
Any reason this is happening?
The text was updated successfully, but these errors were encountered: