yeet
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
#!/usr/bin/env ruby
|
||||
|
||||
$0
|
||||
@@ -0,0 +1,3 @@
|
||||
source 'https://rubygems.org'
|
||||
|
||||
gem '$0'
|
||||
@@ -0,0 +1,16 @@
|
||||
require 'bundler/setup'
|
||||
$:.unshift File.expand_path('../lib', __FILE__)
|
||||
|
||||
# rake spec
|
||||
require 'rspec/core/rake_task'
|
||||
RSpec::Core::RakeTask.new(:spec) { |t| t.verbose = false }
|
||||
|
||||
# rake console
|
||||
task :console do
|
||||
require 'pry'
|
||||
require '${1:gem_name}'
|
||||
ARGV.clear
|
||||
Pry.start
|
||||
end
|
||||
|
||||
$0
|
||||
@@ -0,0 +1,12 @@
|
||||
# `(progn
|
||||
(setq-local pkgs (split-string (string-remove-prefix (concat (doom-project-root) "lib/") (file-name-sans-extension buffer-file-name)) "/" t))
|
||||
(setq-local pkgs-p (eq (length pkgs) 1))
|
||||
(setq-local pkg-module (replace-regexp-in-string " " "::" (capitalize (if pkgs-p (car pkgs) (string-join (butlast pkgs) " "))) nil t))
|
||||
|
||||
(concat "lib/" (file-name-nondirectory buffer-file-name)))`
|
||||
|
||||
module `pkg-module`
|
||||
`(when pkgs-p " VERSION='0.0.1'\n\n")``(concat " class " (if pkgs-p "<< self" (capitalize (car (last pkgs)))))`
|
||||
`%`${0:# Code here}
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user