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 CLI v2.0 #35

merged 85 commits into from Jun 18, 2019


None yet
3 participants
Copy link

commented Jun 11, 2019

This supports all the API v2 functionality, namely accounts and blogs.


  • Authenticate with writeas auth username
  • Log out with writeas logout
  • Sync local anonymous posts to your account with writeas claim
  • Publish a file with writeas publish filename
  • View a list of your blogs with writeas blogs
  • Update a post's language with writeas update --lang en


  • Now you'll list your posts with writeas posts instead of writeas list -- it shows any local anonymous posts, and posts on your account when authenticated
  • writeas-cli is now licensed under the GPL, instead of MIT


  • Fix writeas delete errors not displaying

thebaer added some commits Sep 6, 2018

Support user authentication
Adds new `writeas auth` command and saves user's access token to a new
local configuration file.

This closes #10 / T191
Save authenticated user information in JSON
Instead of using an INI file for the access token, this stores it and
other user information in a single JSON file.
Make authenticated requests
If you're logged in, now requests will be made with the saved token
Move "not auth'd" error to newClient()
This adds a new parameter that determines whether or not authentication
is required, and also returns an error now.
Add `writeas fetch` command
This configures a directory for posts and downloads all posts on the
authenticated account into the directory, organizing collection posts
into their own subdirectories.
Support publishing files
Adds new `writeas publish <file>` command
Save post locally on publish
Only with `writeas publish` right now, and only if posts directory has
already been set up.
Don't require -u flag for writeas auth
Instead of writeas auth -u <username>, now you can just use
writeas auth <username>

thebaer and others added some commits Jun 7, 2019

Merge pull request #29 from writeas/T604
fetch authenticated users posts
add collection listing
adds subcommand colls
lists collections for authenticated user
supports -url flag for listing collection URLs
return proper errors in CmdCollections
fix tabwriter padding
Merge pull request #32 from writeas/T632
update docs for v2
add claim posts to writeas CLI
this adds the ability to claim local posts under an authenticated

removePost is now exported for use the claim command
move to version two of go-writeas
this changes imports to use the github import path
Tweak post claim logging
- Presents a summary before making the request when verbose (-v) enabled
- Successful claims only shown with verbose (-v) enabled
- Failed claims now always mention cause of failure
- A summary of successes / failures shows after logging any failures,
  when verbose (-v) enabled

Ref T194

@thebaer thebaer added this to the 2.0 milestone Jun 11, 2019


This comment has been minimized.

Copy link

commented Jun 11, 2019

just heads up, there is currently no flag, global or otherwise for user


This comment has been minimized.

Copy link
Member Author

commented Jun 11, 2019

Ah, good catch 👍 Was copying things over from commit messages and forgot that it'd changed.

Copy link

left a comment

also noticed that GUIDE and README do not contain the new claim sub command in usage output examples

robjloranger and others added some commits Jun 13, 2019

remove local post save and delete
until the fetch command is included again
update documentation for v2
- remove line about authentication not being supported
- add claim to list of commands in both README and GUIDE
- add auth, blogs and claim example usage in GUIDE

This comment has been minimized.

Copy link
Member Author

commented Jun 18, 2019

This still needs some final tweaks, but I'm going to merge now to simplify the pull request process.

@thebaer thebaer merged commit af64f4c into master Jun 18, 2019

Copy link

left a comment


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.