Skip to content

Instantly share code, notes, and snippets.

View sgsharma's full-sized avatar
💭
Sleeping

Sasha Sharma sgsharma

💭
Sleeping
View GitHub Profile
@AndrewPix
AndrewPix / serializers.py
Last active December 30, 2024 02:13
Integrate django-rest-knox with django-rest-auth
from rest_framework import serializers
from rest_auth.serializers import UserDetailsSerializer
class KnoxSerializer(serializers.Serializer):
"""
Serializer for Knox authentication.
"""
token = serializers.CharField()
@simecek
simecek / rmagic_example.ipynb
Last active January 16, 2021 13:29
How to add R code to your (IPython) Jupyter Notebook
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alces
alces / ansible_local_playbooks.md
Last active November 4, 2025 16:50
How to run an Ansible playbook locally
  • using Ansible command line:
ansible-playbook --connection=local 127.0.0.1 playbook.yml
  • using inventory:
127.0.0.1 ansible_connection=local
@stewsters
stewsters / Slack message
Last active September 17, 2020 01:29
This sends messages as slackbot to slack
/**
* This sends messages as slackbot to slack using groovy
*/
String.metaClass.encodeURL = {
java.net.URLEncoder.encode(delegate, "UTF-8")
}
def address = "https://slack.com/api/"
def method = "chat.postMessage"
@arvindraghavan
arvindraghavan / gist:298550869401add305f7
Last active November 25, 2017 04:08
Installing pandoc on Mac OSX using Homebrew

Starting from scratch (no LaTeX), you can do the following:

$ brew tap phinze/cask
$ brew install brew-cask
$ brew cask install mactex