Skip to content

Instantly share code, notes, and snippets.

View maximveksler's full-sized avatar
Wow

Maxim Veksler maximveksler

Wow
  • Tel Aviv, Israel
  • 19:38 (UTC +03:00)
  • X @mvxlr
View GitHub Profile
Mind Mapping tools for Mac
-- Yes --
iMindQ (DropMind) 100$
MindNode 20$
Curio $100
-- Filtered out --
XMind # Needs java. That sucks.
  • iqvoc - SKOS(-XL) Vocabulary Management System for the Semantic Web.
A great way to assess how your life is going and where you might be able to improve it to have a more balanced and healthy life is to try to be successful in these 6 areas of life:
1) Intimate Relationships
2) Friendships
3) Family
4) Career and Education (livelihood)
5) Time Away from Work (creativity)
6) Drugs/Alcohol (health)
Now you can assess your success in these 6 categories, which is the first step to setting a plan to improve each of them. I've also specified the last 3 categories to fit into another way to view life, which is to ensure you have one aspect that that provides your livelihood (a job), one aspect that allows for a creative outlet (music, painting, writing, etc) because all humans essentially yearn to create something, and one aspect that allows for exercise/health and reduce your drugs and alcohol intake.
1) If you do not have any intimate relationships, you must consider how to improve on this aspect. This might include things like dating sites, going to bars, Tinder, etc. However, my
@maximveksler
maximveksler / FuckingAVFoundation.m
Created February 25, 2014 23:36
Fucking AV Foundation code with audio and video mixing
- (void)buildTransitionCompositionAUDIO:(AVMutableComposition *)composition andVideoComposition:(AVMutableVideoComposition *)videoComposition andAudioMix:(AVMutableAudioMix *)audioMix
{
CMTime nextClipStartTime = kCMTimeZero;
// Add two video tracks and two audio tracks.
AVMutableCompositionTrack *compositionVideoTracks[2];
AVMutableCompositionTrack *compositionAudioTracks[2];
compositionVideoTracks[0] = [composition addMutableTrackWithMediaType:AVMediaTypeVideo preferredTrackID:kCMPersistentTrackID_Invalid];
compositionVideoTracks[1] = [composition addMutableTrackWithMediaType:AVMediaTypeVideo preferredTrackID:kCMPersistentTrackID_Invalid];
@maximveksler
maximveksler / TapeACall_downloader.rb
Last active June 2, 2017 14:52
TapeACall recordings download script
require 'csv'
require 'date'
require 'net/http'
all = CSV.read("TapeACall Recordings.csv")[1 .. -1]
all.each do |x|
csv_date = x[0]
csv_label = x[1]
csv_duration = x[2]
csv_link = x[3]
@maximveksler
maximveksler / memoize-swift3.swift
Last active April 2, 2017 19:19
memoize implementation using swift 3
// Non Recursive
func memoize<T: Hashable, U>(work: @escaping (T)->U) -> (T)->U {
var memo = Dictionary<T, U>()
return { x in
if let q = memo[x] { return q }
let r = work(x)
memo[x] = r
return r
}
@maximveksler
maximveksler / Map.swift
Last active February 14, 2017 00:53
Functional Swift - Examples used in https://gumroad.com/l/natural-swift
import Foundation
func lengthOf(strings: [String]) -> [Int] {
return strings.map { $0.characters.count }
}
let fruits = ["Apple", "Cheery", "Orange", "Pineapple"]
let upperFruits = fruits.map { $0.uppercased() }
let scores = [100, 80, 85]
@maximveksler
maximveksler / LoggerAPI.swift
Created February 5, 2017 05:17
Benchmark extension for IBM Swift HeliumLogger
//
// LoggerAPI.swift
// Collection
//
// Created by Maxim Veksler on 05/02/2017.
//
//
import Foundation
import LoggerAPI
@maximveksler
maximveksler / main.swift
Last active January 24, 2017 21:48
Using #ifdef Xcode to detect debug builds in Swift
func _hackon_FacebookGET(_ stdin: FileHandle) -> Data {
#if Xcode
return "{\"httpMethod\":\"GET\", \"queryStringParameters\":{\"hub.mode\":\"subscribe\",\"hub.challenge\":\"56922036\",\"hub.verify_token\":\"Swift time is the best time\"},\"body\":null,\"isBase64Encoded\":false}".data(using: .utf8)!
#else
return stdin.readDataToEndOfFile()
#endif
}
let input = try Jay().jsonFromData(_hackon_FacebookGET(FileHandle.standardInput))
@maximveksler
maximveksler / Package.swift
Created January 22, 2017 21:58
CI deploy script for: AWS Lambda Swift echo
import PackageDescription
let package = Package(
name: "Collection",
dependencies: [
.Package(url: "https://github.com/gfx/Swift-PureJsonSerializer", majorVersion: 1)
]
)