Skip to content

Instantly share code, notes, and snippets.

View jmartinesp's full-sized avatar

Jorge Martin Espinosa jmartinesp

View GitHub Profile
@melix
melix / Fluent.groovy
Created June 6, 2014 09:55
Fluent class for AsyncTask
package me.champeau.gr8confagenda.app;
import android.os.AsyncTask;
import groovy.lang.Closure;
/**
* An implementation of {@link android.os.AsyncTask} which makes it easy to deal with
* requests/callbacks using Groovy closures
*/
@adamyanalunas
adamyanalunas / KeyboardTableView.swift
Created January 11, 2019 17:34 — forked from douglashill/KeyboardTableView.swift
A UITableView that allows navigation and selection using a hardware keyboard.
// Douglas Hill, December 2018
// Made for https://douglashill.co/reading-app/
import UIKit
/// A table view that allows navigation and selection using a hardware keyboard.
/// Only supports a single section.
class KeyboardTableView: UITableView {
// These properties may be set or overridden to provide discoverability titles for key commands.
var selectAboveDiscoverabilityTitle: String?

Debugging the Swift Toolchain

Use these steps to debug components of the Swift toolchain. This allows you to see Swift's source code from the debugger – instead of disassembly. The debugger can also provide some variable names and values. This has been initially tested with libswiftCore.dylib.

These instructions were updated as of Swift 5.2.1.

Prerequisites

@yanngx
yanngx / FragmentArgumentDelegate.kt
Last active January 19, 2023 09:26
Fragment arguments without hassle !
package be.brol
import android.os.Binder
import android.os.Bundle
import android.support.v4.app.BundleCompat
import android.support.v4.app.Fragment
/**
* Eases the Fragment.newInstance ceremony by marking the fragment's args with this delegate
* Just write the property in newInstance and read it like any other property after the fragment has been created
@perfaram
perfaram / k3_keys.html
Created October 15, 2017 13:44
A backup of parhelia.ch's SMC key informations and structs declarations.
<html><head>
<body>
<center><h1>SMC Keys</h1></center>
<center><h2>K3 Version: 1.30f1
</h2></center>
<p>
<table cellpadding="2" cellspacing="2" border="1" width="100%">
<tr>
<th align=middle>KEY</th>
<th align=middle>TYPE</th>
@m4rtinpf
m4rtinpf / test-ci.sh
Created May 10, 2024 02:44
Record screen for reactivecircus/android-emulator-runner gh action
#!/bin/sh
set -x
echo "Starting the screen recording..."
adb shell "screenrecord --bugreport /data/local/tmp/testRecording.mp4 & echo \$! > /data/local/tmp/screenrecord_pid.txt" &
set +e
npm run test
TEST_STATUS=$?
echo "Test run completed with status $TEST_STATUS"
adb shell "kill -2 \$(cat /data/local/tmp/screenrecord_pid.txt)"