News for hackers. Stuff that matters.

alexjarvis

Re:Ask HN: Flexible, lightweight build automation/CI tool? on Monday December 18, 2017 @04:31PM (#15955696)
bitrise (https://www.bitrise.io) is the best that I've used so far for building iOS apps. Its elite package is also really fast if you can afford it. I've used travis (slow, 45 min build times) and gitlab-ci with a dedicated mac pro runner and bitrise wins hands down for speed and simplicity. Also don't forget fastlane (https://fastlane.tools). Most of my build configuration is in fastlane (for iOS and Android) and bitrise just triggers fastlane via the script step. Good luck!
You could try Flow (https://flow.org) as you're already familiar with JavaScript. I've been using it after primarily using static languages and it's been great so far.
How are blocks not required to be cryptographically verifiable?
Sorry, I wasn't clear, I meant trust-less consensus (proof of work).

Distributed transactions in an RDBMS requires trusting all the hosts it runs on.

No because it's cheap to produce hashes for git.
Postgres doesn't do distributed consensus though does it.
Re:Why Swift Guard Should Be Avoided on Saturday January 02, 2016 @06:25AM (#10825874)
Yes it's more cognitive overhead but it's a more functional than imperative style which usually has many advantages. If the functions are named well (naming being the hardest problem) then it should be easy to read without knowing exactly what the implementation of the function does.
Re:Why Swift Guard Should Be Avoided on Saturday January 02, 2016 @06:18AM (#10825857)
I agree that you can split validation parts into separate functions but this is conflating two concerns, for example the rewriting of the guard statement from

  guard item.count > 0 else {
    throw VendingMachineError.OutOfStock
  }
to

  if count == 0 {
    throw VendingMachineError.OutOfStock
  }
only proves that you can refactor the code to not use guard whereas the article starts by talking about small functions, where you could in fact still use guard in this case.
Re:Ask HN: Freelancer? Seeking freelancer? (January 2016) on Friday January 01, 2016 @01:23PM (#10822689)
SEEKING WORK – London UK, remote ok

Lead iOS Engineer (Swift, Objective-C).

Six years experience creating and publishing apps to Apple and iOS since it was called iPhone OS 3 (2009).

Experience working remote.

Some of my work:

• 6Tribes http://6tribes.com

• WeCycle http://www.travelai.info

Apps that I built for myself:

• ZombieChat http://getzombiechat.com

• Meep http://meep.io

Get in touch!

Email: [email protected]

GitHub: http://github.com/alexanderjarvis

LinkedIn: http://uk.linkedin.com/in/alexanderjarvis/

Re:Limitations of protocols in Swift on Wednesday December 16, 2015 @06:39AM (#10743617)
extensions let you do this with enums (as well as protocols):

  enum Car { 
    case Red 
    case Blue 
  }    
  extension Car { 
    func hello() { 
      print("hello") 
    } 
  } 
  let x = Car.Blue
  x.hello()
https://developer.apple.com/library/ios/documentation/Swift/...

edit: although you can't add a new case to the enum.

Re:Limitations of protocols in Swift on Wednesday December 16, 2015 @06:18AM (#10743545)
And with associated values in enum types they behave in a similar way to case classes in Scala that extend a sealed trait.

For example I've been working on a Json library that stores everything in an enum (ADT):

  public enum JsValue {
    case JsString(String)
    case JsNumber(Double)
    case JsObject([String: JsValue])
    case JsArray([JsValue])
    case JsBoolean(Bool)
    case JsNull
  }
Re:Limitations of protocols in Swift on Wednesday December 16, 2015 @06:04AM (#10743503)
Yeah you're right. If you want to stick with value types and store those values in an Array where the array can only store one type then you have to use an Enum instead of classes. I think there are a few people getting confused by not identifying enums in Swift as a more powerful construct than in C/ObjC.
Re:Apple Delays Release of WatchOS 2 Due to Bug on Wednesday September 16, 2015 @01:08PM (#10228138)
Apparently un-pairing and pairing again fixes the issue, so will give this a try.
Re:Apple Delays Release of WatchOS 2 Due to Bug on Wednesday September 16, 2015 @12:58PM (#10228037)
I'm also having battery issues since the GM release. Beta 5 was fine, but now it doesn't even get through the morning.
Re:Should I use a Swift struct or a class? on Saturday July 04, 2015 @12:55PM (#9830729)
Also why no mention for the enum, the other value type that allows for pattern matching?
Re:Should I use a Swift struct or a class? on Saturday July 04, 2015 @12:52PM (#9830715)
What a stupid, long blog post
Re:Swift Function Fun Facts on Sunday April 19, 2015 @04:07AM (#9402377)
I also ran into this problem a couple of times..

It's not the only issue. I put it down to how new the language is and how many non-critical issues they can fix.

Swift 1.2 has been a massive improvement with incremental compiling and the SourceKit HUD not flickering in my face every few minutes. But still Xcode crashes frequently.

With all the known problems considered, I still find that the advantage of using Swift far outweighs the small number of issues with it in its current version.

Re:Ask HN: What I should do with my life? on Saturday April 11, 2015 @03:39PM (#9360449)
> What are the best places to search for them?

http://workinstartups.com

https://www.siliconmilkroundabout.com

In the meantime work on something you enjoy and can point to as a portfolio piece. Go to meetups and try and give a talk about something you care about.

Re:Ask HN: Freelancer? Seeking freelancer? (December 2014) on Monday December 01, 2014 @10:00AM (#8681320)
SEEKING WORK – Remote – London & Brighton, UK

Full-stack software engineer (iOS / Scala). Loves building creative products, apps especially.

Startup founder with creative design skills and product experience: http://meep.io/download

Seeking part-time or fixed cost contracts for front-end, back-end or both.

Recently delivered a cross-platform activity recognition library in portable C to process inertial data using machine learning algorithms for a Travel startup (amongst other things).

Get in touch!

Email: [email protected]

Phone: +44 (0) 7545 378874

GitHub: http://github.com/alexanderjarvis

LinkedIn: http://uk.linkedin.com/in/alexanderjarvis/

keywords: iOS, Scala, Akka, Play, Functional, Distributed, Swift, Objective-C, ObjC, AWS

Re:Phoenix – Elixir Web Framework on Saturday November 29, 2014 @11:52AM (#8674204)
Could you please explain how PubSub in a cluster "Just Works"? How does it share subscriptions/channels between nodes?

I created a distributed PubSub for the Scala/Akka/Play toolchain a while ago so just wondering how it compares: https://github.com/alexanderjarvis/dubsub

Re:Cache is the new RAM on Thursday November 20, 2014 @04:42AM (#8635006)
http://crate.io is pretty much the system described towards the end of the article.
If you use a different key to encode the message for each client (web or app) then this is not necessary. This is how iMessage works.
It's possible to build a more complete picture of someone's interests based on what they share privately via Facebook chat.

It's also public knowledge that they've been parsing messages for links to then 'like' the appropriate pages inside Facebook.

Rather than debate about how much profit there could be in it, which is entirely down to what the user talks about, I think it is important to realise the potential here even if it not fully realised at this point it time.

Also remember that they are keeping chat history indefinitely in HBase clusters (because they are 'sentimental') so as your habits and interests change over time this will become invaluable data to marketers who want to understand consumer behaviour.

I think it's great that WhatsApp are implementing end-to-end encryption but their now immediate connection with Facebook doesn't sit well with me. Perhaps I'm an idiot, but it doesn't take long to realise that there are perhaps competing interests at play here.

Highly unlikely seeing as Facebook uses the content of your messages to market ads to you, build up a profile of you, identify you and identify trends (links, keywords).

The fact that Facebook owns WhatsApp makes this announcement a big surprise as I think they profit far more with unencrypted messages (although WhatsApp was just delivering, not storing them supposedly).

Older »