4
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Rakefile 使い方

Last updated at Posted at 2020-12-30

概要

Rakefile に関する説明

Rakefile とは

commandラインをまとめたもの。Rakefile を起動させることで、複数のcommand を一気に処理してくれるからすごく助かる。僕の研究室では、texのコンパイルに Omakefile を使ってるがそれに似ている。

Rakefile 中身

task :default dosystem 'rake -T'exitend

desc 'hello NAME'task :hello doname = ARGV[1]puts "Hello #{name}!"exitend

desc 'git pull'task :pull dop comm = "git pull origin main"system commexitend

require 'colorize'desc 'git push'task :push dop comm = "git add -A"system commcomm = "git commit -m 'hoge'"puts comm.greensystem commp comm = "git pull origin main"system commp comm = "git push origin main"system commexitend

  • git の pull や push を自動で行ってくれる。

  • source ~/grad_members_20f/members/FumiyaToyoda/rake.org
4
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?