slipspace 0.1.5 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/lib/slipspace/cli.rb +16 -1
 - data/lib/slipspace/version.rb +1 -1
 - metadata +1 -1
 
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA1:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: 2e0f62f026a2d227591cf3ec6a720b2847d1c96f
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: 21f12fc0dc2edcc4c4a9c94ef5bcc8af39094d10
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 824b489f95409424aaf7d8ab5307415fd9b4df447f88b7588a4659cc568bc01139eb56fe88498ef79d37fad718fda52e7926f518e853b59f145458e1422c7832
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 45000b659eaddf7b0fad78ba5160e9f6534c92eec9eab3c606b52b3abe0cb966a595ea4a01c7f67d2984e6fb098418f73d26891b04f9b8c29f114d6520fc9ad0
         
     | 
    
        data/lib/slipspace/cli.rb
    CHANGED
    
    | 
         @@ -1,15 +1,30 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            require 'thor'
         
     | 
| 
       2 
2 
     | 
    
         
             
            require 'yaml'
         
     | 
| 
      
 3 
     | 
    
         
            +
            require_relative 'stream'
         
     | 
| 
       3 
4 
     | 
    
         | 
| 
       4 
5 
     | 
    
         
             
            module Slipspace
         
     | 
| 
       5 
6 
     | 
    
         
             
                class Navigation < Thor
         
     | 
| 
       6 
7 
     | 
    
         
             
                    include Thor::Actions
         
     | 
| 
       7 
     | 
    
         
            -
                    desc " 
     | 
| 
      
 8 
     | 
    
         
            +
                    desc "prepare", "Install slipspace"
         
     | 
| 
       8 
9 
     | 
    
         
             
                    option :install
         
     | 
| 
       9 
10 
     | 
    
         
             
                    option :name
         
     | 
| 
       10 
11 
     | 
    
         
             
                    def prepare()
         
     | 
| 
       11 
12 
     | 
    
         
             
                      install('slipspace.yml')
         
     | 
| 
       12 
13 
     | 
    
         
             
                    end
         
     | 
| 
      
 14 
     | 
    
         
            +
                    desc "drop", "Enter slipspace"
         
     | 
| 
      
 15 
     | 
    
         
            +
                    def drop(slipspace,dream)
         
     | 
| 
      
 16 
     | 
    
         
            +
                      if !File.exist?(slipspace)
         
     | 
| 
      
 17 
     | 
    
         
            +
                        puts 'Error: Unable to locate slipspace.yml'
         
     | 
| 
      
 18 
     | 
    
         
            +
                        puts 'Shutting down...'
         
     | 
| 
      
 19 
     | 
    
         
            +
                      elsif !File.exists?(dream)
         
     | 
| 
      
 20 
     | 
    
         
            +
                        puts 'Error: Unable to locate dream.yml'
         
     | 
| 
      
 21 
     | 
    
         
            +
                        puts 'Shutting down...'
         
     | 
| 
      
 22 
     | 
    
         
            +
                      else
         
     | 
| 
      
 23 
     | 
    
         
            +
                        portal = Slipspace::Stream.new(YAML::load_file(slipspace), YAML::load_file(dream))
         
     | 
| 
      
 24 
     | 
    
         
            +
                        portal.throttle()
         
     | 
| 
      
 25 
     | 
    
         
            +
                        puts portal.drop()
         
     | 
| 
      
 26 
     | 
    
         
            +
                      end
         
     | 
| 
      
 27 
     | 
    
         
            +
                    end
         
     | 
| 
       13 
28 
     | 
    
         
             
                    private
         
     | 
| 
       14 
29 
     | 
    
         
             
                        def install(template_file)
         
     | 
| 
       15 
30 
     | 
    
         
             
                            install_path = options[:install] ? options[:install] : '.'
         
     | 
    
        data/lib/slipspace/version.rb
    CHANGED