Comments (5)
Hi!
You can not pass directly the credentials path as argument, you need to pass a config file that contains your desired path for the credentials.
In your case it would be something like this (explained here ):
Create /somepath/config.json
with this content:
{
"CRED_PATH": "/Users/ts/client_secret.json"
}
Then execute the command:
$ gcal -C /somepath/config.json generateUrl
from gcal-cli.
thanks. Tested as you suggest but still not working and error message is not really self explaining ;-)
(ts)-(jobs:0)-(~/gcal)
(! 631)-> gcal -C /Users/ts/gcal/config.json generateUrl
[ERROR] Cannot match against 'undefined' or 'null'.
(ts)-(jobs:0)-(~/gcal)
(! 632)-> ls
client_secret.json config.json
(ts)-(jobs:0)-(~/gcal)
(! 633)-> cat config.json
{
"CRED_PATH": "/Users/ts/gcal/client_secret.json"
}
from gcal-cli.
If you include the option --debug
at the end we can get the error stack.
How is the format of your client_secret.json
file? It expects something in this format:
{
"installed": {
"client_id": "foo",
"client_secret": "bar",
"redirect_uris": [
"urn:baz",
"http://localhost"
]
}
}
from gcal-cli.
here is my content (download right away from Google "download json" option). secret parts have been replaced by ...
{
"web:{"client_id":"....apps.googleusercontent.com","project_id":"...","auth_uri":"https://accounts.google.com/o/oauth2/auth","token_uri":"https://accounts.google.com/o/oauth2/token","auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs","client_secret":"..."}
}
from gcal-cli.
I see, when you create your client ID you must choose Other
in Application type
, not Web
.
I'll fix the README specifying it!
from gcal-cli.
Related Issues (7)
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 gcal-cli.