Skip to content

Instantly share code, notes, and snippets.

@grokasm
Created November 27, 2015 01:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save grokasm/5d9def55a0e8022f193e to your computer and use it in GitHub Desktop.
Save grokasm/5d9def55a0e8022f193e to your computer and use it in GitHub Desktop.
Micro Motor Warehouse Dark Force Friday Inventory polling
while true; do curl http://micro-motor-warehouse.com/collections/frontpage/products/the-dark-lords-giveaway.js 2>/dev/null | jq ".variants[]|{qty:.inventory_quantity,opts:.options}|.opts[0]+\" -> \"+.opts[1],.qty"; echo "--------------------------------";sleep .3; done
@grokasm
Copy link
Author

grokasm commented Nov 27, 2015

The command works in any bash terminal in linux. Need jq installed. Link here
The command polls the inventory feed ~3x/second and parses out the variant options and their inventory.
Best of luck.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment