Skip to content

Instantly share code, notes, and snippets.

View dzeyelid's full-sized avatar
🐹
Enjoying developing! 🌠

Kazumi OHIRA dzeyelid

🐹
Enjoying developing! 🌠
View GitHub Profile
@duboisf
duboisf / operations.graphql
Last active July 19, 2024 06:39
Add branch protection to a repo using GitHub's Graphql API
fragment branchProtection on BranchProtectionRule {
allowsDeletions
allowsForcePushes
creator {
login
}
id
isAdminEnforced
requiredStatusCheckContexts
requiredApprovingReviewCount
@iPotaje
iPotaje / example.js
Created April 19, 2016 13:19
Example of Sequelize with sql.js
var lib = require('./patch.js');
var Sequelize = require('sequelize');
var sequelize = new Sequelize('sqlite://dbname', {dialectModulePath: 'sql.js'});
var User = sequelize.define('user', {
username: Sequelize.STRING,
birthday: Sequelize.DATE
});
@wmandai
wmandai / Codeigniter IIS web.config
Last active August 11, 2023 06:24
IIS web.config for codeigniter
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Index">
<match url="^(.*)$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
@tristanfisher
tristanfisher / Ansible-Vault how-to.md
Last active May 27, 2025 10:11
A short tutorial on how to use Vault in your Ansible workflow. Ansible-vault allows you to more safely store sensitive information in a source code repository or on disk.

Working with ansible-vault


I've been using a lot of Ansible lately and while almost everything has been great, finding a clean way to implement ansible-vault wasn't immediately apparent.

What I decided on was the following: put your secret information into a vars file, reference that vars file from your task, and encrypt the whole vars file using ansible-vault encrypt.

Let's use an example: You're writing an Ansible role and want to encrypt the spoiler for the movie Aliens.

@theconektd
theconektd / github.css
Created April 30, 2012 02:11
Github Markdown CSS - for Markdown Editor Preview
body {
font-family: Helvetica, arial, sans-serif;
font-size: 14px;
line-height: 1.6;
padding-top: 10px;
padding-bottom: 10px;
background-color: white;
padding: 30px; }
body > *:first-child {
@toritori0318
toritori0318 / aws_status.pl
Created September 1, 2011 17:34
AWS全リージョンの情報取得(perl版)
use strict;
use VM::EC2;
my $owner_id = $ENV{EC2_OWNER_ID} or die 'EC2_OWNER_ID is required.';
#my $owner_id = shift or die 'aws_status.pl <owner_id>';
my $ec2 = VM::EC2->new;
my @regions = $ec2->describe_regions();
for my $region (@regions) {
# region