Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Matan Abravanel mcmatan

🎯
Focusing
  • Melio
  • Tel Aviv
View GitHub Profile
@jk2K
jk2K / extract_realm_database_android.sh
Last active Apr 24, 2022 — forked from medyo/extract_realm_database_android.sh
how to export realm database, work on Android 5.0+
View extract_realm_database_android.sh
#!/bin/bash
ADB_PATH="/Users/lee/Library/Android/sdk/platform-tools"
PACKAGE_NAME="com.yourcompany.app"
DB_NAME="default.realm"
DESTINATION_PATH="/Users/lee/Downloads/${DB_NAME}"
NOT_PRESENT="List of devices attached"
ADB_FOUND=`${ADB_PATH}/adb devices | tail -2 | head -1 | cut -f 1 | sed 's/ *$//g'`
if [[ ${ADB_FOUND} == ${NOT_PRESENT} ]]; then
echo "Make sure a device is connected"
else
@sooop
sooop / DragTableController.swift
Created Feb 9, 2017
NSTableView reordering row with drag and drop
View DragTableController.swift
//
// ViewController.swift
// DragTable
//
// Created by Anna Kim on 2017. 2. 9..
// Copyright © 2017년 Anna Kim. All rights reserved.
//
import Cocoa
@takuoka
takuoka / AutoGrowingTextField.swift
Last active Jan 18, 2022
Example of an NSTextField that expands its height automatically. https://github.com/DouglasHeriot/AutoGrowingNSTextField
View AutoGrowingTextField.swift
import Cocoa
// https://github.com/DouglasHeriot/AutoGrowingNSTextField
// for AutoLayout
class AutoGrowingTextField: NSTextField {
var minHeight: CGFloat? = 100
@ratazzi
ratazzi / duplicate_xcode_project_target.rb
Last active Apr 8, 2022
Duplicate Xcode Project Target with Ruby
View duplicate_xcode_project_target.rb
#!/usr/bin/env ruby
require 'rubygems'
require 'xcodeproj'
name = 'test_copy'
proj = Xcodeproj::Project.open('test.xcodeproj')
src_target = proj.targets.find { |item| item.to_s == 'test' }