aboutsummaryrefslogtreecommitdiffhomepage
path: root/services/nuldoc/Rakefile
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-02-01 02:28:10 +0900
committernsfisis <nsfisis@gmail.com>2026-02-01 02:28:10 +0900
commitcd16ed5d6b46d91ae9ac7b2237d6405ad6715a4a (patch)
tree0e00d7caf3031fa86decaa0cbc226cc1e521b914 /services/nuldoc/Rakefile
parentd08e3edb65b215152aa26e3518fb2f2cd7071c4b (diff)
parent1964f77d03eb647dcf46d63dde68d7ae7301604f (diff)
downloadnsfisis.dev-cd16ed5d6b46d91ae9ac7b2237d6405ad6715a4a.tar.gz
nsfisis.dev-cd16ed5d6b46d91ae9ac7b2237d6405ad6715a4a.tar.zst
nsfisis.dev-cd16ed5d6b46d91ae9ac7b2237d6405ad6715a4a.zip
Merge branch 'feat/ruby-rewrite'
Diffstat (limited to 'services/nuldoc/Rakefile')
-rw-r--r--services/nuldoc/Rakefile28
1 files changed, 28 insertions, 0 deletions
diff --git a/services/nuldoc/Rakefile b/services/nuldoc/Rakefile
new file mode 100644
index 00000000..4dfe4317
--- /dev/null
+++ b/services/nuldoc/Rakefile
@@ -0,0 +1,28 @@
+require 'rubocop/rake_task'
+require_relative 'lib/nuldoc'
+
+RuboCop::RakeTask.new
+
+desc 'Build the site'
+task :build do
+ config = Nuldoc::ConfigLoader.load_config(Nuldoc::ConfigLoader.default_config_path)
+ profile = ENV.key?('PROFILE')
+ Nuldoc::Commands::Build.run(config, profile: profile)
+end
+
+desc 'Start development server'
+task :serve, [:site] do |_t, args|
+ config = Nuldoc::ConfigLoader.load_config(Nuldoc::ConfigLoader.default_config_path)
+ Nuldoc::Commands::Serve.run(config, site_name: args[:site], no_rebuild: false)
+end
+
+desc 'Create new content'
+task :new, [:type] do |_t, args|
+ config = Nuldoc::ConfigLoader.load_config(Nuldoc::ConfigLoader.default_config_path)
+ Nuldoc::Commands::New.run(config, type: args[:type], date: nil)
+end
+
+desc 'Benchmark the build'
+task :bench do
+ sh 'hyperfine', '--warmup', '1', 'rake build'
+end