19 lines
		
	
	
		
			428 B
		
	
	
	
		
			Ruby
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			428 B
		
	
	
	
		
			Ruby
		
	
	
		
			Executable File
		
	
	
	
	
| #!/usr/bin/env ruby
 | |
| APP_PATH = File.expand_path('../config/application', __dir__)
 | |
| 
 | |
| require_relative '../config/boot'
 | |
| require_relative '../lib/mastodon/cli/main'
 | |
| 
 | |
| begin
 | |
|   Chewy.strategy(:mastodon) do
 | |
|     Mastodon::CLI::Main.start(ARGV, debug: true) # Enables the script to rescue `Thor::Error`
 | |
|   end
 | |
| rescue Thor::Error => e
 | |
|   Thor::Shell::Color
 | |
|     .new
 | |
|     .say_error(e.message, :red)
 | |
|   exit(1)
 | |
| rescue Interrupt
 | |
|   exit(130)
 | |
| end
 |