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

Expose export parameters as a text string #1944

Closed
planemad opened this issue Apr 12, 2013 · 5 comments
Closed

Expose export parameters as a text string #1944

planemad opened this issue Apr 12, 2013 · 5 comments

Comments

@planemad
Copy link

I am planning on making a series of maps for India that require multiple tilemill projects. Each time I want to export a map of a new place, I have to manually change the export area and resolution from the export dialog in each project.

I keep a separate document with the export values so that I can copy paste them, but it involves a bit of clicking for each export and eats into the fun of using tilemill.

A single text box where I could paste the export parameters as a string will itself be very useful. This could also allow a future feature of saving export presets and using it between projects.

@springmeyer
Copy link
Member

generally is sounds like you want to start exporting from the command line. Are you aware you can do this?

See #1742 for base usage per operating system.

@planemad
Copy link
Author

perfect! I did not know command line export was possible. It would be nice if such things got visibility somewhere in the reference. I'll close this.

@planemad
Copy link
Author

I tried exporting via the command line which gives the following output which does not make much sense:

mes-MacBook-Pro-2:Resources Me$ ./node ./index.js export india-streets-2 --format=png --bbox=80.2751,13.0726,80.2878,13.0843 --width=400
Note: Unknown option "profile" in config file.
Note: Unknown option "updatesVersion" in config file.
Note: Unknown option "updatesTime" in config file.
Usage: node ./index.js [options...]
Commands: export project
export

What am I doing wrong?

@springmeyer
Copy link
Member

sounds like you are hitting a common confusion with --format, see #1836

So are you trying to export mbtiles or a single png image? If the latter then do:

cd /Applications/TileMill.app/Contents/Resources/
./node ./index.js export india-streets-2 output.png --format=png

I'm afraid, however, that the command line options handling does not appear to be working well for --format=png. For example I presume you may want to alter the bbox of the export, but in this case the --bbox appears to be ignored for --format=png as it as the command line interface evolved to automate mbtiles exports mainly. If you need this then you can file a different bug report. To workaround in the meantime you may need to script changing your project settings manually.

@planemad
Copy link
Author

Thanks, this works now, I had missed out the export filename.

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

No branches or pull requests

2 participants