Last active
          August 29, 2015 14:05 
        
      - 
      
- 
        Save lolgear/15bc4f49c28278ef4e20 to your computer and use it in GitHub Desktop. 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | attr_accessor( | |
| :path, | |
| :name | |
| ) | |
| def initialize(path,name) | |
| self.path = path | |
| if name | |
| @name = name | |
| end | |
| end | |
| def path=(path) | |
| if self.looks_like_name(File.basename(path)) | |
| @name = File.basename(path) | |
| end | |
| @path = path | |
| end | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment