Comments (4)
Extra note: I've also modify your app to be able to read GeoJSON files and extract tiles from a polygon. You can see what I've done here: https://github.com/aurelien-m/wms-tiles-downloader/pull/2/files.
from wms-tiles-downloader.
Hi @aurelien-m 👋
Thanks for opening this issue! I'm open to any proposals you have to fix this, we can briefly discuss it and either you can open a PR with a fix or I can work on it. Up to you 😉 Let me know which way you prefer.
from wms-tiles-downloader.
Speaking of possible solution, the first and most simple thing that comes to my mind is to add new ClientOption
:
func WithBasicHTTPAuth(username, password string) ClientOption {
return func(c *Client) {
c.username = username
c.password = password
}
}
Then we can access both username
and password
in the request
method of the Client
via c.username
, c.password
and use it to set it on the request object as you did in the code snippet above 😉 What do you think?
from wms-tiles-downloader.
Hey @lmikolajczak!
So I've actually done something similar in my own fork: https://github.com/aurelien-m/wms-tiles-downloader/pull/1/files. I've also added useBasicAuth
in the client struct to check if we need authentication or not. I can create a draft pull request out of it if you think it's a good start.
And by the way, I haven't done a lot of Go, so don't hesitate if you see anything clumsy 😄
from wms-tiles-downloader.
Related Issues (10)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wms-tiles-downloader.