Skip to content

Instantly share code, notes, and snippets.

View fedeisas's full-sized avatar
🎯

Fede Isas fedeisas

🎯
  • Buenos Aires, Argentina
View GitHub Profile
@JackTheDane
JackTheDane / Manipulate attachments (Item Compose).OUTLOOK.yaml
Last active October 30, 2022 07:14
Adds, gets, and removes attachments from a message or an appointment in Compose mode.
name: Manipulate attachments (Item Compose)
description: >-
Adds, gets, and removes attachments from a message or an appointment in
Compose mode.
host: OUTLOOK
api_set: {}
script:
content: |
$("#addBase64").click(addMultipleAttachments);
@eddy8
eddy8 / MyQueueException.php
Last active June 15, 2021 01:11
use laravel queue standalone v5.3
<?php
/**
* 异常处理类
*/
use \Illuminate\Contracts\Debug\ExceptionHandler;
class MyQueueException implements ExceptionHandler
{
/**
@ethanpil
ethanpil / wp-secure.conf
Created May 12, 2017 16:16
Wordpress Security for NginX
# wp-secure.conf
#
#
# This file includes common security considerations for wordpress using nginx.
#
# The goal is to block actions which are usually dangerous to wordpress.
# Additionally, we block direct access to PHP files and folders which should not
# be accessed directly from a browser.
#
# Also have included exceptions for plugins that are known to require this access.
@Jeff-Russ
Jeff-Russ / PHP: numeric array keys.md
Last active January 27, 2023 14:06
PHP: numeric array keys

PHP's Numeric & String Key Type Juggling

Arrays in PHP treat integer and string integers synonymously. If you set $a['1'] = '1' and access $a[1] you will get '1'. This is because php juggled your string key to an integer before assigning it; the assigment was actually made to an integer key. PHP also juggles in the process of accesssing too which means if you try to access [1] with ['1'] it will work. Therefore there is no real distinction between string integers and real integer, you can use them interchangably.

Remember that '1.0' does not equal '1' or 1 with strict comparison. This is true of array keys as well: you can have both ['1.0'] and ['1'] and they would be different elements but not [1] and ['1'].

@StefanieD
StefanieD / Readme.md
Created July 3, 2015 15:17
Install and use Supervisord with AWS Elastic Beanstalk, Symfony 2 and RabbitMq Bundle
  • Place the supervisord.conf under .ebextensions/supervisor/

  • Place the supervisor.config under .ebextensions/

  • Place the data_import_consumer.conf under .ebextensions/supervisor/

@samklr
samklr / ipython-nbserver.py
Last active March 26, 2020 21:52
Install Ipython Notebook on a VM and Launch it as a server in a Cloud Platform. Here, in Google Compute Engine.
##### Install a lot of stuff first #####
$sudo apt-get update
##install python
$ wget http://09c8d0b2229f813c1b93-c95ac804525aac4b6dba79b00b39d1d3.r79.cf1.rackcdn.com/Anaconda-2.0.1-Linux-x86_64.sh
$ sudo bash anaconda........sh
##install necessary libs
$ sudo apt-get install -y python-matplotlib python-tornado ipython ipython-notebook python-setuptools python-pip
@bsweger
bsweger / useful_pandas_snippets.md
Last active April 19, 2024 18:04
Useful Pandas Snippets

Useful Pandas Snippets

A personal diary of DataFrame munging over the years.

Data Types and Conversion

Convert Series datatype to numeric (will error if column has non-numeric values)
(h/t @makmanalp)

@phansys
phansys / MyVendor_MyBundle_Cache_CacheInvalidator.php
Created March 14, 2013 20:06
Added basic comprobation to check valid entity keys.
<?php
namespace MyVendor\MyBundle\Cache;
/**
* Better than using
* $this->getDoctrine()->getManager()->getConfiguration()->getResultCacheImpl()->delete(...);
* in your controllers
*/
use Doctrine\ORM\Event\OnFlushEventArgs;
use Symfony\Component\DependencyInjection\ContainerAware;
@davidmatas
davidmatas / mou.html
Last active March 1, 2023 16:42
highlight syntax for Mou.app
<!-- Highlight syntax for Mou.app, insert at the bottom of the markdown document -->
<script src="http://yandex.st/highlightjs/7.3/highlight.min.js"></script>
<link rel="stylesheet" href="http://yandex.st/highlightjs/7.3/styles/github.min.css">
<script>
hljs.initHighlightingOnLoad();
</script>
@dhrrgn
dhrrgn / _instructions.md
Created September 28, 2011 03:50
A Sublime Text 2 Project file for Fuel

Sublime Text 2 Fuel Project File

Description

This sets up your Sublime Text 2 Fuel project so that your tab and line ending settings are all correct. This way if you like spaces or something, you can still use them by default.

Usage

  1. Create a file named fuel.sublime-project in your Fuel root directory (not the web root).
  2. Open with Sublime Text 2