Skip to content

Instantly share code, notes, and snippets.

@mcindea
Last active December 10, 2019 10:43
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 mcindea/223534e25e07eb20620fd33ace959978 to your computer and use it in GitHub Desktop.
Save mcindea/223534e25e07eb20620fd33ace959978 to your computer and use it in GitHub Desktop.
Download or extract logs from CodeShip
# I made this script because CodeShip for some reason doesn't have an option to download the logs, so any logs bigger
# than your browser can handle will make it hang. You just need the jq installed for this script to work.
# How-to:
# If you open the Developer console and look at Network when you click a log, you will see something with the name:
# 'jet_log?start_index=' <- Just right click it, Copy => Copy as cURL.
# Then simply execute the command and pipe it to a file, or the following command:
# jq -c .service_log[].payload | tr -d \" | base64 -d
# Append this to your .bashrc, to use it at the end of the cURL command with a pipe, as so:
# <super long cURL command> | codeship-extract
alias codeship-extract='jq -c .service_log[].payload | tr -d \" | base64 -d'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment