Git Product home page Git Product logo

gcloud-help's Introduction

gcloud help

crawl

This repo automatically scrapes the help text for gcloud and puts it in this Git repo.

Scraping is automated with GitHub Actions. Every day, the workflow installs the latest gcloud release, and crawls the output of gcloud help and all subgroups and subcommands. The output is placed in the gcloud/ directory.

This produces the same content as the official CLI reference, in text form, with history. This enables diffing the help text of two gcloud releases.

How is this useful?

You can use this repo to identify changes in gcloud releases.

For example, compare 374.0.0 and 375.0.0 (looks like lots of help text formatting...).

GitHub also provides an undocumented RSS feed feature, which even lets you filter changes in certain paths. For example, you can subscribe to changes to the gcloud builds surface in your RSS reader of choice. Party like it's 2009!

Using this information you can count the number of unique CLI surfaces provided by gcloud:

$ find gcloud -type f | wc -l
    9816

Or find the longest CLI surface:

$ find gcloud -type f | awk '{print length, $0}' | sort -rn | head -10 | sed -e "s+/+ +g"
81 gcloud alpha compute instance-groups managed rolling-action stop-proactive-update
80 gcloud beta compute instance-groups managed rolling-action stop-proactive-update
79 gcloud alpha compute resource-policies create vm-maintenance maintenance-window
78 gcloud alpha compute resource-policies create vm-maintenance concurrency-limit
76 gcloud alpha compute public-delegated-prefixes delegated-sub-prefixes delete
76 gcloud alpha compute public-delegated-prefixes delegated-sub-prefixes create
75 gcloud compute instance-groups managed rolling-action stop-proactive-update
75 gcloud beta compute public-delegated-prefixes delegated-sub-prefixes delete
75 gcloud beta compute public-delegated-prefixes delegated-sub-prefixes create
74 gcloud alpha metastore services databases tables remove-iam-policy-binding

All text content is owned by Google, licensed under the Creative Commons Attribution 4.0 License.

Code in the repo is owned by me, licensed under the Apache 2.0 license.

gcloud-help's People

Contributors

imjasonh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gcloud-help's Issues

Scrape more history

Rewrite repo history with commits for all gcloud versions going back as far as possible.

Since each scrape takes ~2-3h today, and there are 375 versions, this might take somewhere between 1-2 months. So maybe let's make scraping faster first?

Diff between alpha/beta/GA surfaces

Maybe just something as simple as a Bash script to identify surfaces that exist in gcloud/alpha/ and gcloud/beta/ and gcloud/, and surface any diffs. This could highlight alpha/beta surfaces that are on their way to becoming GA.

Eliminate the go parts

Go is only run to roughly/terribly parse help output to identify subgroups and commands. It's nothing that couldn't be done in Bash.

Document path-specific RSS feeds

GitHub has (poorly documented) RSS support, including (I think!) filtering by paths, so you could subscribe to changes to gcloud/compute/whatever, get emails, whatever. Let's document that.

Identify breaking changes

A diff between vX and vY can tell you when a surface is deleted, or changed in breaking ways (e.g., an arg that was optional is now required).

Slap together some Bash to find those kinds of changes in a diff and... I dunno... alert about them? Somehow?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.