Skip to content

Instantly share code, notes, and snippets.

Avatar

Rodrigo Deodoro roddds

View GitHub Profile
@roddds
roddds / download_slack_history.py
Created Dec 27, 2022
Download a Slack channel's full history, including thread replies
View download_slack_history.py
"""
$ export SLACK_TOKEN="xoxb-1234567890-1234567890123-GaT2364GEv72wRpDfSkqn2Wk"
$ python download_slack_history.py CHANNELID
Downloading messages...
...............................................................done!
Downloading threads
................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
@roddds
roddds / speedcontrols.user.js
Last active Oct 6, 2020
Add speed controls to SAP Litmos
View speedcontrols.user.js
// ==UserScript==
// @name Litmos speed controls
// @namespace rodrigo.deodoro@carta.com
// @version 0.2
// @description Add speed controls to SAP Litmos videos
// @author Rodrigo Deodoro
// @match https://*.litmos.com/course/*
// ==/UserScript==
(function () {
@roddds
roddds / remove_empty_dirs.py
Last active Sep 20, 2021
Recursively delete all empty directories
View remove_empty_dirs.py
import os
for dirpath, dirnames, files in os.walk('.'):
if not (files or dirnames):
os.rmdir(dirpath)
View das_download.py
import subprocess
import asyncio
import os
import re
from collections import namedtuple
from bs4 import BeautifulSoup
import requests
'''
View reminder.py
import time
import sys
import sched
from pync import Notifier
def main():
seconds = int(sys.argv[1]) * 60
text = sys.argv[2]
View Timer decorator.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@roddds
roddds / gist:a1f42bae598028ac7809
Last active Dec 8, 2020 — forked from raddevon/gist:67935d320ee9b726d19d
Adobe tries to strong-arm me into keeping Creative Cloud
View gist:a1f42bae598028ac7809

To everyone who got here through Twitter or Facebook or Hacker News or whatever: THIS IS NOT ME.

The "Me" in this transcript is @raddevon, who shared his story first on reddit.


List of incompetent jackasses who can't check a source if their lives depended on it:

View gist:5cb26bd4c9fe7466b6eb
[run]
branch = True
omit = *migrations*,
*urls*,
*test*,
*admin*,
*scripts*,
*models*,
pipes/config/*,
pipes/manage.py,
@roddds
roddds / admin.py
Created Jul 27, 2015
Showing foreign key attributes on Django Admin
View admin.py
from django.contrib import admin
from django.core.urlresolvers import reverse
from .models import Carro, Fabrica, Pais
class CarroAdmin(admin.ModelAdmin):
list_display = ('nome', 'fabrica', 'pais')
def queryset(self):
qs = super(CarroAdmin, self).queryset()
View aliases.sh
alias runserver="python manage.py runserver_plus"
alias sp="python manage.py shell_plus"
alias manage="./manage.py"
alias syncdb="manage syncdb --migrate"
alias dif="git diff"
alias add="git add --all"
alias gs="git status"
alias commit="git commit -m"
alias gl="git log --graph --decorate --all"