git/Make Zip: Possibility to exclude files
Hey guys and gals,
I don't really know, where the right place would be to ask for this, so I just try it here. :) As I recently decided to develop my addon with IntelliJ, I needed to add some project files to the git repository. Of course they should be persisted and shared, so I can just clone anywhere and start working. I am a really big fan of the "Make Zip" functionality in the Git Control Panel. Sadly though, the resulting package would contain all those meta files, which are in no way needed in every player's addon folder. My solution at the moment would be to generate the Zip file on my own again and upload it the old way. That would be quite a bummer though. So my question is: Could there be a way to add some kind of exclude/ignore functionality to this feature? Maybe via an additional section in the dialog, where one could check off files, which are should not be included. Or maybe just look for an ignore file of some kind (zamignore.txt) which would contain files and folders, which should be excluded in general? Thanks for any feedback/replies on this. Maybe I'm just a lazy diva. :) -Boris |
You are lazy indeed. I was removing the intetlliJ files manually before zipping them :D
But the idea is nice and if there is an automatic possibility I can get lazy too :banana: |
Quote:
|
Quote:
Edit: or just script it with something like bash, powershell etc or C# Script Edit 2: Also Git make zip just zips the entire branch so I don't think its intended to have files excluded :) |
Quote:
It's really not that hard to build the zip file myself though, so it's not that big of a deal. Just want that feature to stay useful. |
git-archive is a built-in command to create archive, you can use it to create the zip locally, no need to download it from github.
It also allows you to exclude files/directories via gitattributes Just create a .gitattributes file: Code:
UnwantedDir/ export-ignore Code:
git archive --prefix ABC/ -o ABC.zip COMMIT |
Okay, so to be a bit more clear on this matter: I am not using github but the integrated git here on esoui.com. When doing so, there is a convencience method to create a new zip file, modify addon information as version, description, and changelog, and publish said zip file from within a nice little wizard directly on this page.
That being sad: Is there the possibility of esoui.com using git-archive to create the zip file (would make sense), so I'd just have to sneak in the .gitattributes file and everything could already work? I will try that out later for sure, though maybe someone has already some insight here? |
Ah, I wasn't reading carefully. Haven't tried that here on esoui, but as you wrote, it would make sense if it used git-archive ;)
|
Quote:
|
Quote:
Quote:
|
Yeah, pretty sure that'd have to be a new feature.
You could setup the .gitattributes as mentioned above, then add a post-commit hook to make the zip. You'd still have to manually upload it, but saves one more step. Alternatively, you could keep those meta files on a separate branch (if it's stuff like screenshots and addon descriptions). |
All times are GMT -6. The time now is 12:51 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI