Skip to content

Instantly share code, notes, and snippets.

View RPallas92's full-sized avatar

Ricardo Pallas RPallas92

View GitHub Profile
@gimenete
gimenete / readme.md
Last active March 9, 2024 16:36
Notas para orientación profesional como programador

Tras este tweet que publiqué

He sido freelance, emprendedor y trabajo desde hace años para empresas USA de diversos tamaños en remoto como programador fullstack. Ahora en GitHub. Si puedo ayudar a alguien en orientar su carrera, mis DMs están abiertos. Ask me anything.

he recibido muchos mensajes y escribo aquí algunos de los consejos que he dado en resumen. Nota: algunas cosas son concretas de trabajar en España. Si vas a trabajar desde Sudamérica sólo una nota: tienes la ventaja de la zona horaria para trabajar con EEUU.

Inglés

Tener un buen nivel de inglés es fundamental para poder trabajar con clientes extranjeros. El conocimiento del idioma tiene que mantenerse en el tiempo. Es como mantenerse en forma física; si lo dejas, lo pierdes. Personalmente aunque trabajo 100% en inglés desde hace bastantes años, intento crearme un entorno diario con el idioma para no perderlo:

@sz332
sz332 / index.js
Last active August 29, 2019 07:53
Working example of bull and external processor
// index.js
const path = require('path');
const Queue = require('bull');
let queue = new Queue('test queue', 'redis://192.168.99.100:6379');
queue.process(1, path.join(__dirname, './processor.js'))
queue.on('completed', function(job, result) {
console.log("Completed: " + job.id + ", result = " + JSON.stringify(result));
@DrBoolean
DrBoolean / three_envs.js
Last active May 24, 2021 02:31
Tail of three envs
const compose = (f, g) => x => f(g(x))
const Id = x =>
({
fold: f => f(x),
map: f => Id(f(x))
})
Id.of = Id
const Tuple = (_1, _2) =>
@josete89
josete89 / gist:fc6f648a8ea9e927d23cc1196a544ecc
Last active December 7, 2017 12:13
Crashing with MLMultiArray
 
func resize(to: CGFloat) -> UIImage {
let scale = to / self.size.width
let newHeight = self.size.height * scale
UIGraphicsBeginImageContext(CGSize(width: to, height: newHeight))
self.draw(in: CGRect(x: 0, y: 0, width: to, height: newHeight))
let newImage = UIGraphicsGetImageFromCurrentImageContext()
UIGraphicsEndImageContext()
@mishagray
mishagray / DefaultingJSONDecoder.swift
Created November 13, 2017 16:44
defines DefaultingJSONDecoder and CodingKeyWithDefaults
//
// DefaultingDecoder.swift
//
// Created by Michael Gray on 10/12/17.
//
import Foundation
// swiftlint:disable force_cast file_length
@josete89
josete89 / gist:952c89a5f7e1eff4734421a4f7d61a39
Last active August 29, 2017 07:22
Swift 4 Continuation Monad
// Playground - noun: a place where people can play
public func id<A>(x : A) -> A {
return x
}
public func error<A>(_ x : String) -> A {
assert(false, x)
}
/// The Continuation Monad
@edsiper
edsiper / kubernetes_commands.md
Last active May 6, 2024 08:53
Kubernetes Useful Commands
//
// RealmSwift+Codable.swift
//
// Created by Michael Gray on 8/16/17.
//
import Foundation
import RealmSwift
// swiftlint:disable line_length identifier_name
@lattner
lattner / TaskConcurrencyManifesto.md
Last active May 19, 2024 07:58
Swift Concurrency Manifesto
@lattner
lattner / async_swift_proposal.md
Last active April 21, 2024 09:43 — forked from oleganza/async_swift_proposal.md
Concrete proposal for async semantics in Swift

Async/Await for Swift

Introduction

Modern Cocoa development involves a lot of asynchronous programming using closures and completion handlers, but these APIs are hard to use. This gets particularly problematic when many asynchronous operations are used, error handling is required, or control flow between asynchronous calls gets complicated. This proposal describes a language extension to make this a lot more natural and less error prone.

This paper introduces a first class Coroutine model to Swift. Functions can opt into to being async, allowing the programmer to compose complex logic involving asynchronous operations, leaving the compiler in charge of producing the necessary closures and state machines to implement that logic.