diskutil erasevolume HFS+ 'RAM Disk' `hdiutil attach -nobrowse -nomount ram://XXXXX`
where XXXXX
is the size of the RAM disk in terms of memory blocks.
Notes:
Code Sandbox oddities observed while working on LogicRoom exercises
codesandbox.io does its best to give the impression of a locally running environment, but the abstraction is sometimes a bit leaky. Here's some weirdness (with possible fixes)
The console.log statement is actually proxied via a server and executed at a later stage. That sometimes results in weird behaviours, as the value of some field on an object can be different when it is printed than when it was logged ... The fix is making something like this and using that instead:
// ==UserScript== | |
// @name Prevent Jane redirect | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description Out-trick the neanderthals responsible for redirecting the Concord customers to the Jane page with JS | |
// @author Carl-Erik Kopseng | |
// @match https://no.concord.es/support/nedlastinger/ | |
// @icon https://www.google.com/s2/favicons?sz=64&domain=concord.es | |
// @grant none | |
// @run-at document-start |
/* Used on https://minside.fremtindservice.no/passings */ | |
(function() { | |
const priceCols = document.querySelectorAll('.MuiBox-root div div div:nth-child(3n+1) div:nth-child(1)'); | |
let sum=0; | |
for(let n of priceCols) { | |
if( n?.nextSibling?.textContent === 'NOK') { | |
sum+=parseInt(n.textContent,10) | |
} |
class PublicPlanData extends AbstractFixture implements OrderedFixtureInterface | |
{ | |
public function load(ObjectManager $manager) | |
{ | |
$planUnlimitedFree = new PlanInfo(); | |
$planUnlimitedFree->setName('FREE UNLIMITED PLAN') | |
->setAmount(0) | |
->setCurrency('USD') | |
->setDescription('Special plan for users that should never pay for using the service') |
VirtualBox only supports the x86 platform, so the default installation instructions for Vagrant does not work on Apple silicon. Thankfully Vagrant has a VMWare Provider (more on providers here), and so if I can get VMWare running on my M1 MacBook, I should be able to run Vagrant as well!
These are my notes during figuring this out.
We are in luck, as VMWare released this just a few weeks ago.
/* | |
This is a typical example of a codebase I inherited 😭 | |
I mean, where do I even start ... | |
- direct DOM manipulation | |
- toggling display: none instead of not rendering, ... | |
- unclear data paths and constant heavy lookups | |
Oh, are you surprised that this stinking pile of shit is full of bugs? Me neither. | |
#kilowott #ninestack |
<!-- This is just to get syntax highlighting: | |
https://support.pingidentity.com/s/question/0D51W00008BoxciSAB/how-to-customise-page-expired-handling | |
--> | |
<!-- So the middle part of the velocity template would look like this --> | |
<div class="ping-body-container"> | |
<div class="ping-messages"> | |
<div> | |
The page you are trying to access is no longer available. | |
</div> | |
</div> |
Rename kebab-case files to PascalCase and vice versa | |
---------------------------------------------------- | |
- Check the `require()` calls for what to `npm install` | |
- If you need to modify something else than `*.js` files, just modify the `find` command somewhat |
Hvor mange har ikke irritert seg grønn over at det er 317 uleste meldinger i TrueGroups når man logger inn, vel vitende om at man allerede har lest disse på epost? Det finnes jo dessverre ingen "Merk alle som lest" funksjonalitet, så da må man lage det sjøl :)
Dette skriptet finnes nå som eget prosjekt her: https://github.com/fatso83/truegroupshacks