parent
b548be9c8f
commit
6a8f9b10d9
@ -0,0 +1,2 @@
|
||||
class ProjectLanguage < ApplicationRecord
|
||||
end
|
@ -0,0 +1,17 @@
|
||||
class CreateProjectLanguages < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
create_table :project_languages do |t|
|
||||
t.string :name
|
||||
t.integer :position
|
||||
t.integer :projects_count, :default => 0
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
names = %w(Ruby C C# C++ HTML Haml CSS JavaScript Python PHP Java JSON JSX Lex Shell Objective-C Cycript Clojure Go Grace Gradle GraphQL Dart Elixir Erlang Perl R Reason Sass Slice SVG)
|
||||
names.each do |name|
|
||||
ProjectLanguage.find_or_create_by!(name: name)
|
||||
end
|
||||
|
||||
end
|
||||
end
|
Loading…
Reference in new issue