Skip to content

Instantly share code, notes, and snippets.

View brnpimentel's full-sized avatar
🎯
Focusing

Bruno Pimentel brnpimentel

🎯
Focusing
View GitHub Profile
@nghuuphuoc
nghuuphuoc / gist:8331575
Created January 9, 2014 09:22
chmod files to 644 and all folders to 755
$ find . -type d -print0 | xargs -0 chmod 0775
$ find . -type f -print0 | xargs -0 chmod 0664
@albofish
albofish / EntrustFixFacade.php
Created September 2, 2016 10:48
Entrust Laravel 5.3 Blade syntax fix
<?php namespace App\Extensions\EntrustFix;
use Zizaco\Entrust\EntrustFacade;
class EntrustFixFacade extends EntrustFacade
{
//
}
@fay59
fay59 / icloud-album-download.sh
Last active July 24, 2024 23:57
Download entire iCloud shared albums
#!/bin/bash
# requires jq
# arg 1: iCloud web album URL
# arg 2: folder to download into (optional)
function curl_post_json {
curl -sH "Content-Type: application/json" -X POST -d "@-" "$@"
}
setTimeout(function() {
function getAllModules() {
return new Promise((resolve) => {
const id = _.uniqueId("fakeModule_");
window["webpackJsonp"](
[],
{
[id]: function(module, exports, __webpack_require__) {
resolve(__webpack_require__.c);
}
@fzldn
fzldn / beautifier.js
Last active July 28, 2023 18:28
VS Code Laravel Blade formatter using extension Beautify 1.5.0 by HookyQR with js-beautify hacks
...
Beautifier.prototype.beautify = function() {
...
var source_text = this._source_text;
// BEGIN
source_text = source_text.replace(/\{\{(--)?((?:(?!(--)?\}\}).)+)(--)?\}\}/g, function(m, ds, c, dh, de) {
@paulolorenzobasilio
paulolorenzobasilio / git-is-merged
Last active May 23, 2024 16:57
Check if source branch has been already merged into destination branch
#!/usr/bin/env bash
#
# Check if source branch has been already merged into destination branch
# https://stackoverflow.com/questions/226976/how-can-i-know-if-a-branch-has-been-already-merged-into-master
#
git_is_merged () {
merge_destination_branch=$1
merge_source_branch=$2