Skip to content

Instantly share code, notes, and snippets.

View jeffkreeftmeijer's full-sized avatar
🦞

Jeff Kreeftmeijer jeffkreeftmeijer

🦞
View GitHub Profile
module Concerns::Token
def self.included(base)
base.after_initialize(:set_token)
end
def set_token
self.token = SecureRandom.hex if new_record?
end
end
@jeffkreeftmeijer
jeffkreeftmeijer / Gemfile
Last active August 29, 2015 14:07
Import
gemspec
class Version
include Comparable
attr_reader :major, :minor, :patch
def initialize(number)
@major, @minor, @patch = number.split('.').map(&:to_i)
end
def to_a
[major, minor, patch].compact
<html>
<head>
<style>
body{
margin: 0;
}
div{
padding: 10px 10px 10px 10px;
}
#!/usr/bin/env ruby
Dir['**/*.rb'].each do |path|
lines = File.readlines(path)
new_lines = lines.dup
lines.each do |line|
if line =~ /^# encoding: utf-8/i || line !~ /\S/
new_lines.delete_at(new_lines.index(line))
else
" Tab -> , EOL ->
set list
set listchars=tab:💩💩,eol:¬
@roy1 ✓
@roy2 ✓
@roy3 ✓
@roy4 ✓
@roy5 ✓
@roy6 ✓
@roy7 ✓
@roy8 ✓
@roy9 ✓
@roy10 ✓
def process(input)
commands = {
'q' => 'Goodbye',
'tweet' => 'tweeting',
'dm' => 'direct messaging',
'help' => 'helping'
}
if command = commands[input]
puts command
@jeffkreeftmeijer
jeffkreeftmeijer / gist:3124699
Created July 16, 2012 20:03
StillMaintained is closing down on August 1st, 2012

Stillmaintained has been running since November 2010 and we're currently hosting more than 6700 project pages.

The problem we were trying to solve was to get more information about open source project maintenance statuses. We partially achieved this goal, since a lot of people created status pages for their projects. A problem we're facing now is that people don't come back to update their projects' statuses after it changed, resulting in information that's out of date, and that's even worse than no data at all.

Of course, this problem could be solved by keeping an eye on commit dates and such, but the project lost a lot of momentum over the last couple months. The amount of projects being registered and the amount of contributions by the community dropped drastically. Also, I'm currently too busy with other things to keep investing time in it.

So, we're closing down Stillmaintained on August 1st, 2012. Of course, the project will stay available on [Github](https://github.com/jeffkreeftmeijer/stillmaintain