Skip to content

Instantly share code, notes, and snippets.

# tar_custom_format_arrow.R
# store as parquet, load as an Arrow Table
format_arrow_table <- function() {targets::tar_format(
read = function(path) {arrow::read_parquet(path, as_data_frame = FALSE)},
write = function(object, path) {arrow::write_parquet(object, path, version = "2.0")},
marshal = function(object) as.data.frame(object),
unmarshal = function(object) arrow::Table$create(object),
repository = "default"
@shoaloak
shoaloak / fix-entitlements.sh
Last active April 23, 2024 21:24
This script automates the process of granting specific entitlements to a set of iOS binaries, resolving issues related to 'Operation not permitted' errors, e.g., when accessing /private/var/mobile/Containers.
#!/bin/bash
# Author: Shoaloak (Axel Koolhaas) 2024
# Description: Fix iOS binary entitlements/access for "Operation not permitted"
ENTITLEMENT="com.apple.private.security.container-manager"
binaries=("sh" "bash" "zsh" "dash" # Shell
"ls" "cat" "find" "cp" "mv" # File management
"rm" "mkdir" "rmdir" "touch"
"file" "ln" "du" "scp"
"chmod" "chown" "chgrp" # Permissions
@ramzesenok
ramzesenok / CustomSwipeActions.swift
Created March 20, 2022 17:19
SwiftUI custom swipe actions cause there are none outside of the List
struct ContentView: View {
@State var titles = ["Cell #1", "Cell #2", "Cell #3", "Cell #4"]
var body: some View {
NavigationView {
ScrollView {
VStack(spacing: 0) {
ForEach(self.titles, id: \.self) { title in
HStack {
Text(title)
term description reference
Phase ADNI phase link
ID Record ID link
RID Record ID link
PTID Patient ID link
SITEID Site ID link
V
@jeffochoa
jeffochoa / 1.ProcessClass.php
Last active April 23, 2024 21:22
Understanding Laravel pipelines
<?php
namespace App\Features;
use App\Features\FirstTask;
use App\Features\SecondTask;
use Illuminate\Pipeline\Pipeline;
// *Naming things is hard* ... So, this is a class called `ProcessClass` that `run()` some text ¯\_(ツ)_/¯
class ProcessClass
@MightyPork
MightyPork / usb_hid_keys.h
Last active April 23, 2024 21:20
USB HID Keyboard scan codes
/**
* USB HID Keyboard scan codes as per USB spec 1.11
* plus some additional codes
*
* Created by MightyPork, 2016
* Public domain
*
* Adapted from:
* https://source.android.com/devices/input/keyboard-devices.html
*/
@evantoli
evantoli / GitConfigHttpProxy.md
Last active April 23, 2024 21:19
Configure Git to use a proxy

Configure Git to use a proxy

In Brief

You may need to configure a proxy server if you're having trouble cloning or fetching from a remote repository or getting an error like unable to access '...' Couldn't resolve host '...'.

Consider something like:

@lavantien
lavantien / modern-software-engineering-resources.md
Last active April 23, 2024 21:17
Modern Software Engineering Resources

Modern Software Engineering

Knowledge and Education should be open and free. Hierarchy and Exploitation must be abolished.

  • Z. (down) Notes below. Avoid funnel sales, if you spent money, there's something wrong. Also don't forget good OpSec, self defense gears, and physical/mental strength.
  • A. (go) Development Environment.
  • B. (go) Complementary Subjects (Linguistics, English, Security, OpSec, Psychology, Anthropology, History, Philosophy, Economics, Business, Defense, Cooking, Xenology, Self Defense).
  • C. (go) Fundamentals of Science and Technology (Logic, Physics (Classical/Quantum Mechanics, Thermodynamics, Electricity, Relativity, Electronics, Electromagnetism, Optoelectronic, Semiconductor, Fusion), Mathematics (Calculus, Linear Algebra, Statistics, Applied Math), Game Theory, Biology, Medical, and Their Applications).
  • D. ([go](#d-computer-science-and-competitiv
@lumynou5
lumynou5 / youtube-commenter-names.user.js
Last active April 23, 2024 21:17
Make YouTube display the names of commenters instead of their handles.
// ==UserScript==
// @name YouTube Commenter Names
// @version 1.5.17
// @description Make YouTube display the names of commenters instead of their handles.
// @author Lumynous
// @license MIT
// @match https://www.youtube.com/*
// @match https://studio.youtube.com/*
// @noframes
// @downloadURL https://gist.github.com/lumynou5/74bcbab54cd9d8fcd3c873fffbac5d3d/raw/youtube-commenter-names.user.js
@catalinmiron
catalinmiron / README.md
Created April 16, 2024 20:36
Expo app.json Apple Privacy Manifest

About

The privacy details that you may need to add for Apple Privacy Manifest.

This config plugin it's already available from expo >=50.0.17 (Part of this PR by aleqsio)

Tip

Read more about Privacy Manifest File from Apple docs