Testing callbacks in Elixir
Elixir’s variable scoping means you can’t test callbacks like you might in other languages. Message passing to the rescue!
http://thepugautomatic.com/2015/09/testing-callbacks-in-elixir/
Charging for stuff with Phoenix & Stripe
A demo web app shows how to use Phoenix with the Commerce.Billing package.
Simplifying Integration Tests for Dialyzer
I try to build a simple framework for running Dialyzer on my Elixir integration tests – http://bit.ly/1OkOoSZ
Phoenix web framework example applications
Inspired by sails101, we decided to create a GitHub organization for example apps in Elixir based Phoenix framwork. Here is the link to that:
https://github.com/phoenix-examples
It would be great if we get more people to contribute to it. This will help newbies to understand and explore the framework more. Also, please let us know your thoughts on this.
Let me know via Twitter: @yedhukrishnan or email: yedhukrishnan@yahoo.com
Experiment: Porting Rawkets Game to Elixir/Phoenix
Experimenting with porting the basic Rawkets game (https://github.com/robhawkes/rawkets; nodejs) to Elixir/Phoenix. Rawkets is like Asteriods but there no asteriods and it’s mulitplayer. Project is at https://github.com/paaschpa/phoenix-maze and whatever I have working may (or may not) be playable at http://canarymod16.cloudapp.net/rawkets.
Blog post: Please get along with my Ex
Last weekend I read this on Twitter:
I think my biggest annoyance with #elixirlang so far is that every library feels the need include “ex” somewhere in their name…
Read my thoughts on this here: http://trivelop.de/2015/09/17/please-get-along-with-my-ex/
Elixir 1.1.0 RC0 Available On ChocolateyNuGet
The Elixir 1.1.0 RC0 package has been posted to ChocolateyNuGet. You can get the package here
Interoperability with C via Ports
I’ve released a free ElixirSips episode on Interoperability with C via Ports and the corresponding source code. Hope you enjoy it!
A Quick Dip into Ecto Types
A quick and dirty example of how to create a custom type. In this post I implement a type that allows you to use atoms in your models.
Enjoy!
MixStar - Mix task stars GitHub repositories in your mix.exs
MixStar stars GitHub repositories that your project depends on. You just type mix deps.star, MixStar executes mix deps.get internally and stars GitHub repositories. Enjoy!
docker_dna - create a Dockerfile from a Docker hub image's family tree
Docker DNA gives you the convenience of referencing another developer’s Dockerfile without the risk. Instead of your image being directly generated from someone else’s directives, it assembles a new Dockerfile by tracing the ancestors of a given repository image and concatenating the results.
The result is a Dockerfile that you are in total control of and whose source is in a single place (not spread across repos/hub pages).
View on Github
Exq - Resque / Sidekiq compatible job processing library new release
New release of Exq - an Elixir job processing library compatible with Resque / Sidekiq
You can use it to integrate Elixir with your existing Rails application, or if you need a durable job queue to survive application restarts.
Do not crash the Agent
Be cautious about code run in an Agent process. If it crashes, the agent will crash and state will be lost:
From Functions |> Processes
I wrote a post based on my talk at @ElixirBLR. A step by step journey from Functions |> Processes
apn4ex - sending push notifications to APNS in Elixir
Good news, everyone! From now on you are no longer required to write wrappers around apns4erl or implement your own APNS libraries in Elixir - recently I’ve published initial (but stable - we are using slightly modified fork of it in a big production) version of apns4ex. Any feedback is highly appreciated!
2048 Game in Elixir for Practice
I wrote an implementation of the well known 2048 game to practice my Elixir skills. Originally it should have been a Phoenix application using channels to communicate with the frontend, but it ended out with an “offline” app running in the shell using ASCII as UI elements.
It uses tty_sl to grap arrow keys from the shell.
Screenshot:
Source code here: https://github.com/lasseebert/two48
Hopefully someone can learn something from this :)
Chocolatey NuGet Package For Elixir v1.1.0-beta
Sorry it’s taken me a little while to get to this but I just pushed up the ChocolateyNuGet (CNG) package for Elixir v1.1.0-beta. It’s here: https://chocolatey.org/packages/Elixir/1.1.0-beta A few things to note:
1.) You will need to append the -pre to the CNG install command to install it since as far as CNG is concerned it’s beta software.
2.) I modified the Erlang version dependency. Prior to this one I had the dependency as being only the very latest version of Erlang on CNG. Since that’s not strictly needed I modified the version to >= 17 and <= latest version of 18 which is on CNG.
3.) It may not show up in the normal package search on CNG. I mean I just tried to find the link and I searched packages including prerelease and it didn’t turn up for some reason. If you have a problem finding it, the link I shared will take you right to it.
4.) Those of you on Windows please try this out and let me know if there are any issues.
Elixir docker images
If you are using docker you should check https://hub.docker.com/r/matteosister/elixir/ I try to keep up with the language versions as soon as they are out!
Part 1 of my adventures diving into Ecto
An adventure setting up an Ecto project with sample data including all my mistakes and missteps.
