Skip to content

Instantly share code, notes, and snippets.

@r3m0t
r3m0t / memfs+4.6.0.patch
Created January 5, 2024 12:13
memfs PR
diff --git a/node_modules/memfs/lib/node.js b/node_modules/memfs/lib/node.js
index d4b5f87..b640837 100644
--- a/node_modules/memfs/lib/node.js
+++ b/node_modules/memfs/lib/node.js
@@ -287,7 +287,7 @@ class Link extends events_1.EventEmitter {
return link;
}
setChild(name, link = new Link(this.vol, this, name)) {
- this.children.set(name, link);
+ this.children.set(this.vol.caseSensitive ? name : name.toLowerCase(), link);
@r3m0t
r3m0t / makemigrations.py
Created April 27, 2017 20:55
Migration conflict file
# coding: utf-8
"""Cause git to detect a merge conflict when two branches have migrations."""
# myapp/management/commands/makemigrations.py
# you'll need myapp/management/commands/__init__.py and myapp/management/__init__.py in PY2, see Django docs
from __future__ import absolute_import, unicode_literals
import io
import os
import six
@r3m0t
r3m0t / check_ra.py
Created November 26, 2016 11:09
Resident Advisor watcher
# vim: autoindent et ts=4 sw=4 ft=python
import requests
import lxml.html
import traceback
URL = 'https://www.residentadvisor.net/event.aspx?event_id'
SLACK_URL = 'https://hooks.slack.com/services/Twebhook_url_herek'
def ticket_available(url):
@r3m0t
r3m0t / example_bind_once.html
Created February 28, 2014 14:15
Angular digest_limit example
<!doctype html>
<html>
<!--
a far simpler alternative to pasvaz.bindonce.
Use the once directive to remove all watchers from the children and replace
them with one.
-->
<head>
<script src="/lib/jquery/jquery.js"></script>
<script src="/lib/angular/angular.js"></script>