(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
#!/usr/bin/env python | |
from Foundation import NSUserNotification | |
from Foundation import NSUserNotificationCenter | |
from Foundation import NSUserNotificationDefaultSoundName | |
from optparse import OptionParser | |
def main(): | |
parser = OptionParser(usage='%prog -t TITLE -m MESSAGE') |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
//: #typealias & associatedtype magic | |
//: ##Let's make a protocol without typealias (now associatedtype) | |
protocol Testable { | |
} | |
//: ##And another one with typealias | |
//: You could think, that the below typealias is just making | |
//: a typealiast for Int. In fact, we actually created a |
# https://leetcode.com/problems/median-of-two-sorted-arrays/ | |
from bisect import bisect_left | |
from itertools import takewhile | |
class Solution(object): | |
def count_prefix(self, start_idx, st, char): | |
""" Starting from the start index, checks how many times given character | |
repeated""" |
git remote add upstream https://github.com/whoever/whatever.git
git fetch upstream
// | |
// AlamofireObjectMapper+Rx.swift | |
// AlamofireObjectMapper | |
// | |
// Created by Ozgur on 28/01/2017. | |
// Copyright © 2017 Ozgur. All rights reserved. | |
// | |
import AlamofireObjectMapper | |
import Alamofire |
#!/bin/bash -e | |
echo "🤡 Applying carthage 12 and 13 workaround 🤡" | |
xcconfig=$(mktemp /tmp/static.xcconfig.XXXXXX) | |
# For Xcode 12 make sure EXCLUDED_ARCHS is set to arm architectures otherwise | |
# the build will fail on lipo due to duplicate architectures. | |
CURRENT_XCODE_VERSION=$(xcodebuild -version | grep "Build version" | cut -d' ' -f3) | |
echo 'EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_1200 = arm64 arm64e armv7 armv7s armv6 armv8' > $xcconfig | |
echo "EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_1200__BUILD_$CURRENT_XCODE_VERSION = arm64 arm64e armv7 armv7s armv6 armv8" >> $xcconfig |