-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Entry points for gdal-utils package #5282
Conversation
As per "[gdal-dev] gdal-utils: About GDAL Python Utilities" thread, an overview and intro page for the gdal-utils sub project.
I don't know if this is the right place for this info. Feel free to move/edit/adjust.
…gdal-utils-mhw
Co-authored-by: Even Rouault <even.rouault@spatialys.com>
Co-authored-by: Even Rouault <even.rouault@spatialys.com>
Co-authored-by: Even Rouault <even.rouault@spatialys.com>
Co-authored-by: Even Rouault <even.rouault@spatialys.com>
sorry for the noisy commit history, I didn't understand how using the Github resolve conversation and commit buttons worked.
Adapted from https://stackoverflow.com/questions/23708231/git-shallow-clone-clone-depth-misses-remote-branches Note important amendments from comments (don't use single quote, also limit fetch depth).
Fixes: ``` --------------------------- gdalinfo.exe - System Error --------------------------- The code execution cannot proceed because VCRUNTIME140D.dll was not found. Reinstalling the program may fix this problem. ```
As per "gdal-utils: improve command line in Windows and ditch .bat wrappers OSGeo#5281"
I don't know how to write tests, especially so when it comes to setup.py. Sorry, but I'm going to need help with this part! This is how it works on my laptop. Dev environment:
|
It seems this PR is on top of #5222 ? which I've just merged. Could you git rebase this pull request on top of latest master (something like "git fetch upstream master; git rebase upstream/master", replace upstream by origin or whatever remote name you've chosen for the OSGeo/gdal repository) so that this PR only shows the specific changes. |
'gdal_merge = scripts.gdal_merge', | ||
... ] | ||
""" | ||
xx = [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe console_scripts
instead of xx
?
I'm not familiar with rebase. I've read over https://www.atlassian.com/git/tutorials/rewriting-history/git-rebase a couple times and understand the purpose but when I attempt to apply it I end up in a series of merge conflicts that I can't resolve (in the way that I'm familiar with in merging branches). I'm going to keep picking at it because clearly this an important process to learn, but I don't know how long that's going to take. :) note: I use Atlassian docs because they're well written but the git gui I use is Git Extensions. |
or just recreate a new branch and cherry-pick the commits of interest |
I highly recommend to try github desktop. It's super easy to rebase and
pick the relevant commits with it. You can also reorder and squash commits
by drag and drop alone.
…On Fri, 11 Feb 2022, 18:44 Even Rouault, ***@***.***> wrote:
I'm not familiar with rebase. I've read over
https://www.atlassian.com/git/tutorials/rewriting-history/git-rebase a
couple times and understand the purpose but when I attempt to apply it I
end up in a series of merge conflicts that I can't resolve (in the way that
I'm familiar with in merging branches). I'm going to keep picking at it
because clearly this an important process to learn, but I don't know how
long that's going to take. :)
or just recreate a new branch and cherry-pick the commits of interest
—
Reply to this email directly, view it on GitHub
<#5282 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGJBBLI5OAGF3KD3ULBWLTDU2U4GNANCNFSM5N7T4AHA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you commented.Message ID:
***@***.***>
|
superseded per #5296 |
@idanmiara thanks for the Github Desktop recommendation. I'm exploring it now. The drag and drop reordering and squashing of commits is very nice, so intuitive! I'm perplexed why there's no graph visuals for branch merge history and relationships. Maybe that will come clear in time. In the meantime I can use it and Git Extensions side by side for that purpose. I took @rouault's suggestion and cherry picked the relevant commit, into a new PR. I just can't wrap my head around rebase today. |
What does this PR do?
Modifies
setup.py
so that whenpip install gdal-utils
is run all of the .py files in./scripts
are turned into native platform executable scripts that call the .py file using the appropriate interpreter. Although developed to improve the experience on Windows the implementation is cross platform (due to upstream magic by setuptools and/or distutils) and also is better for linux (c.f. https://click.palletsprojects.com/en/8.0.x/setuptools/?highlight=entry_points).Benefits for the user is that after install the gdal python utility scripts are available from the command line immediately, just like all the first class binary utiltiies, e.g. gdalinfo, gdal_translate, and without needing to use .py extension with the name. Gdal edit is just
gdal_edit
.What are related issues/pull requests?
gdal-utils: improve command line in Windows and ditch .bat wrappers #5281
Tasklist
Environment