ChanServ changed the topic of #crystal-lang to: The Crystal programming language | https://crystal-lang.org | Fund Crystal's development: https://crystal-lang.org/sponsors | GH: https://github.com/crystal-lang/crystal | Docs: https://crystal-lang.org/docs | Gitter: https://gitter.im/crystal-lang/crystal
Sankalp has quit [Ping timeout: 268 seconds]
Sankalp has joined #crystal-lang
Sankalp has quit [Ping timeout: 248 seconds]
Sankalp has joined #crystal-lang
_ht has joined #crystal-lang
Sankalp has quit [Ping timeout: 248 seconds]
Sankalp has joined #crystal-lang
Sankalp has quit [Ping timeout: 256 seconds]
Sankalp has joined #crystal-lang
Sankalp has quit [Ping timeout: 256 seconds]
Sankalp has joined #crystal-lang
irc_user has joined #crystal-lang
ober has joined #crystal-lang
_ht has quit [Remote host closed the connection]
<FromGitter> <ondreian> `Path["/home/crystal/~/some/project"]` is not a valid path, it's treating `~` like a string literal instead of expanding it to the home directory of the current user
<FromGitter> <ondreian> Sorry for the late response, but i was in intermittent connectivity for awhile and gitter does not work well in those situations at all
<FromGitter> <ondreian> It should instead be expanding this to `/home/crystal/some/project`
<FromGitter> <ondreian> Ultimately it's treating it like a String when file paths are not actually Strings
<FromGitter> <Blacksmoke16> but what if you did `cd ~ && mkdir -p '~/some/project'`
<FromGitter> <Blacksmoke16> you can have a directory named `~`
_whitelogger has joined #crystal-lang
<riza> typically if you want to expand the ~ or . / .., you need to use a special function to expand them
<riza> eg https://crystal-lang.org/api/1.4.0/Path.html#expand(base:Path|String=Dir.current,*,home:Path|String|Bool=false,expand_base=true):Path-instance-method
<FromGitter> <Blacksmoke16> `Path["~/some/project"].expand home: true` would do what you want
<riza> i think the default behavior of home is true as well
<FromGitter> <Blacksmoke16> Naw it's false by default
<riza> thats interesting... and it might well be the cause of a bug or two I've been living with for quite some time
<FromGitter> <ondreian> The false behavior bit me on an upgrade a week ago
<FromGitter> <ondreian> ```code paste, see link``` ⏎ ⏎ i'm not quite sure what's going on here why the are prefixed with `::`? Does this have the same meaning as Ruby? [https://gitter.im/crystal-lang/crystal?at=62fea44b6837563d1c4c2274]
<FromGitter> <ondreian> To me, that looks like it should compile
<riza> I can't see it in gitter for some reason
<riza> oh you didn't post the code, just the error
<riza> you're passing in uid as an i64 but your overload wants an ui64
<riza> method signature says: uid: Int64, overload says: uid : ::UInt64
<riza> don't worry about teh prefix ::
<FromGitter> <Blacksmoke16> what does false behavior have to do with that error?
hightower4 has joined #crystal-lang
<riza> i think that error is unrelated to the false behavior
hightower3 has quit [Ping timeout: 248 seconds]
<FromGitter> <Blacksmoke16> the `::` prefix basically means like "top level reference"
<FromGitter> <Blacksmoke16> can also be used with methods. E.g. say you added your own `raise` method but still want to call the default one, could do `::raise "oh no"`
<FromGitter> <ondreian> ah yeah, thanks
renich has joined #crystal-lang
Sankalp has quit [Ping timeout: 248 seconds]
Sankalp has joined #crystal-lang
Sankalp has quit [Ping timeout: 248 seconds]
Sankalp has joined #crystal-lang