Straight to Maintenance
Initialize the droplet with dokku app pre-setup
Initialize the droplet with dokku app pre-setup
unless Rails.env.production? | |
connection = ActiveRecord::Base.connection | |
connection.tables.each do |table| | |
connection.execute("TRUNCATE #{table}") unless table == "schema_migrations" | |
end | |
sql = File.read('db/import.sql') | |
statements = sql.split(/;$/) | |
statements.pop |
CREATE TABLE `yok_bolumler` ( | |
`id` int(10) NOT NULL AUTO_INCREMENT, | |
`fakulteId` varchar(40) NOT NULL, | |
`universiteId` int(6) NOT NULL, | |
`name` varchar(255) NOT NULL, | |
PRIMARY KEY (`id`), | |
KEY `fakulteHash` (`fakulteId`) | |
) ENGINE=MyISAM; | |
INSERT INTO `yok_bolumler` (`id`, `fakulteId`, `universiteId`, `name`) VALUES |
/* | |
* capturing from UVC cam | |
* requires: libjpeg-dev | |
* build: gcc -std=c99 capture.c -ljpeg -o capture | |
*/ | |
#include <stdint.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <string.h> |