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

Ignore .git files #120

Merged
merged 6 commits into from
Sep 4, 2019
Merged

Ignore .git files #120

merged 6 commits into from
Sep 4, 2019

Conversation

matt-lumer
Copy link
Contributor

@matt-lumer matt-lumer commented Jul 9, 2019

This causes issues on Windows machines due to file handles not being released

Issue #, if available:

Description of changes:
Added .git to the list of excluded files, similar to the python one which has additional files.
.git causes "WindowsError: [Error 5] Access is denied: c:\temp\.git\objects\*"

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

This causes issues on Windows machines due to file handles not being released
@sriram-mv
Copy link
Contributor

Thanks for this change! is there a unit test you could write for this as well?

@kamilfb
Copy link

kamilfb commented Aug 9, 2019

I've had the same issue on Windows 10 and implementing the fix locally does resolve the problem.

@khamaileon
Copy link
Contributor

@matt-lumer .git files are ignored since the last release. You should cancel your pull request.

@matt-lumer
Copy link
Contributor Author

@khamaileon Can you show me where this change was made? I checked this source file and found
no changes are made in develop or master. I confirmed also CopySource itself is not changed. I also downloaded version 21 and I see the same error

JavaMavenWorkflow:MavenCopyArtifacts failed
PermissionError: [WinError 5] Access is denied: 'C:\Users\mlumer\AppData\Local\Temp\tmpq_zfvkcg\.git\objects\pack\pack-c29e65c05c1a495bc4d83ba6a70fc1fad621ae75.idx'

sam --version
SAM CLI, version 0.21.0

@khamaileon
Copy link
Contributor

@matt-lumer Sorry mate, I was looking at the python builder. There should be a way to globally include or exclude files inside serverless.yml. It would solve a lot of packaging issues..

@matt-lumer
Copy link
Contributor Author

Np, I got all excited :) Yes ultimately I agree it would be nice to have configuration through the files and not buried within the app. Java really suffers from having a subdirectory so I'll get on the unit test and hopefully we'll have this promoted

@matt-lumer
Copy link
Contributor Author

@thesriram I added the unit test, sorry for such a long delay. Can you review?

@matt-lumer
Copy link
Contributor Author

@sanathkr @jfuss If anyone can do a quick sign off, this should be fast and would be appreciated!

@awood45
Copy link
Member

awood45 commented Sep 4, 2019

Thanks for the contribution!

@awood45 awood45 merged commit c01647f into aws:develop Sep 4, 2019
@matt-lumer
Copy link
Contributor Author

@awood45 Thanks so much!!

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

Successfully merging this pull request may close these issues.

5 participants