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

Empty file list should raise and error #62

Open
asmfreak opened this issue Dec 15, 2018 · 3 comments
Open

Empty file list should raise and error #62

asmfreak opened this issue Dec 15, 2018 · 3 comments
Labels

Comments

@asmfreak
Copy link

asmfreak commented Dec 15, 2018

This is a somewhat following issue #39 and PR #42.
The way excludeFileList works currently will somewhat fail on {''} as it is an alternative to '*' in .gitignore-like files. It excludes all files as love-release performs substring search (file:find) on a file name to exclude it and an empty string will be found in any string. Instead of erroring on empty file list, love-release fails on Mac and/or Windows with the following cryptic error message:

../env/bin/love-release -W
{
  title = 'Title',
  package = 'executable',
  loveVersion = '11.1',
  version = '0.0.1',
  author = 'Author Name',
  email = 'invalid@example.com',
  description = nil,
  homepage = 'URL',
  identifier = 'executable',
  excludeFileList = { ''} ,
  compile = false,
  projectDirectory = '/game/',
  releaseDirectory = '/game/releases',
}
/usr/bin/lua5.1: ...e/env/share/lua/5.1/love-release/scripts/windows.lua:46: executable.love: No such file or directory
stack traceback:
	[C]: in function 'assert'
	...e/env/share/lua/5.1/love-release/scripts/windows.lua:46: in function 'release'
	...e/env/share/lua/5.1/love-release/scripts/windows.lua:80: in function <...e/env/share/lua/5.1/love-release/scripts/windows.lua:75>
	(tail call): ?
	...a-love/env/share/lua/5.1/love-release/pipes/args.lua:117: in function 'args'
	...ocks/rocks-5.1/love-release/2.0.9-1/bin/love-release:11: in main chunk
	[C]: ?
@MisterDA
Copy link
Owner

Thanks for the bug report!
Do you have a patch that fixes this bug? I don’t have a Mac to test it on.

@asmfreak
Copy link
Author

I don't actually know where in the codebase to fix this.
Also, it is not a Mac problem. I'm sorry, I may have described the problem inaccurately. It fails not on Windows or Mac. It would fail on any platform during Windows or Mac build as with an empty file list it won't generate a .love file. The subsequent error during Windows or Mac is just a consequence of that.

@MisterDA MisterDA added the bug label Apr 7, 2019
@MisterDA
Copy link
Owner

This seems to be fixed by PR #66 and commit 5be593f.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants