sudo mkdir /private/tmp
sudo chmod 1777 /private/tmp
xcrun
xcrun simctl list devices //to list all simulators
xcrun simctl delete // to delete specific device
#!/usr/bin/env bash | |
# https://docs.docker.com/install/linux/docker-ce/ubuntu/ | |
sudo apt-get install apt-transport-https ca-certificates curl software-properties-common | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | |
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable" | |
sudo apt-get update | |
sudo apt-get install docker-ce | |
# https://docs.docker.com/compose/install/ |
def update_user_social_data(strategy, *args, **kwargs): | |
"""Set the name and avatar for a user only if is new. | |
""" | |
print 'update_user_social_data ::', strategy | |
if not kwargs['is_new']: | |
return | |
full_name = '' | |
backend = kwargs['backend'] |
############################################################################### | |
# The MIT License | |
# | |
# Copyright 2012-2014 Jakub Jirutka <[email protected]>. | |
# | |
# 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 |
############################################# | |
# Push de la rama actual | |
git push origin $rama_actual | |
############################################# | |
# Volver a un commit anterior, descartando los cambios | |
git reset --HARD $SHA1 | |
############################################# | |
# Ver y descargar Ramas remotas |
# Modify this file accordingly for your specific requirement. | |
# http://www.thegeekstuff.com | |
# 1. Delete all existing rules | |
iptables -F | |
# 2. Set default chain policies | |
iptables -P INPUT DROP | |
iptables -P FORWARD DROP | |
iptables -P OUTPUT DROP |
import json | |
from rojoverdeajo.espaciofisico.models import zona | |
#obtener todas las zonas | |
zonas = Zona.objects.all() | |
#construir una lista de diccionarios que representen a las zonas | |
lista = [{'pk': zona.pk, 'zona': zona.zona} for zona in zonas] | |
#convertir eso en un json |