{"comment":{"created_at":"2011-10-24T13:34:40Z","body":"Good idea! I don't think I knew that `File.expand_path` would convert `~` in to the proper path. This should be implemented, it's a lot more readable and solid.","updated_at":"2011-10-24T13:34:40Z","url":"https://api.github.com/repos/meskyanichi/backup/issues/comments/2503422","id":2503422,"user":{"avatar_url":"https://secure.gravatar.com/avatar/3b520db94a0d08263122648c6755e334?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"3b520db94a0d08263122648c6755e334","url":"https://api.github.com/users/meskyanichi","id":54708,"login":"meskyanichi"}},"action":"created","issue":{"number":204,"created_at":"2011-10-24T12:19:36Z","pull_request":{"diff_url":null,"patch_url":null,"html_url":null},"body":"Hi there,\r\n\r\nwhat about changing\r\n\r\n```ruby @path = path.sub(/^\\~\\//, \"#{ENV['HOME']}/\")``` \r\n\r\nto \r\n\r\n```ruby @path = File.expand_path(path)```\r\n\r\n at https://github.com/meskyanichi/backup/blob/develop/lib/backup/storage/local.rb#L73 ?\r\n\r\nAnd \r\n\r\n```ruby\r\n    ##\r\n    # Adds new paths to the @paths instance variable array\r\n    def add(path)\r\n      @paths << path\r\n    end\r\n\r\n    ##\r\n    # Adds new paths to the @excludes instance variable array\r\n    def exclude(path)\r\n      @excludes << path\r\n    end\r\n```\r\n\r\n```ruby\r\n    ##\r\n    # Adds new paths to the @paths instance variable array\r\n    def add(path)\r\n      @paths << File.expand_path(path)\r\n    end\r\n\r\n    ##\r\n    # Adds new paths to the @excludes instance variable array\r\n    def exclude(path)\r\n      @excludes << File.expand_path(path)\r\n    end\r\n```\r\nat https://github.com/meskyanichi/backup/blob/develop/lib/backup/archive.rb#L36 . I'm not quite sure what to do with relative paths in the configuration file. \r\n\r\n/deg","comments":1,"title":"Expand path in archive.rb / local.rb","updated_at":"2011-10-24T13:34:40Z","url":"https://api.github.com/repos/meskyanichi/backup/issues/204","id":2032987,"assignee":null,"milestone":null,"closed_at":null,"user":{"avatar_url":"https://secure.gravatar.com/avatar/9f112ca52563131ea3855a10db79f1b3?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"9f112ca52563131ea3855a10db79f1b3","url":"https://api.github.com/users/maxmeyer","id":114236,"login":"maxmeyer"},"html_url":"https://github.com/meskyanichi/backup/issues/204","labels":[],"state":"open"},"legacy":{"issue_id":2032987,"comment_id":2503422}}