Skip to content

Instantly share code, notes, and snippets.

View mic2100's full-sized avatar

Mike Bardsley mic2100

  • North Lincolnshire
  • 03:31 (UTC +01:00)
View GitHub Profile
@mic2100
mic2100 / slack_history.py
Created August 17, 2017 09:47 — forked from Chandler/slack_history.py
Download Slack Channel/PrivateChannel/DirectMessage History
# MIT License
# Copyright (c) 2016 Chandler Abraham
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#!/usr/bin/env bash
while read url; do
echo "$url"
re="soundcloud://users:([0-9]+)"
responseText=$(curl "$url" | grep soundcloud://users:)
if [[ $responseText =~ $re ]]; then
echo ${BASH_REMATCH[1]};