Comment

Comment by pathikrit

Why not respond with both X and Y? e.g. for the last 3 character thing, here would be an appropriate response:

To get the last 3 characters, do `echo ${foo: -3}`. Are you trying to get the file extension though? What if the extension is not 3 characters e.g. `foo.jpeg`? You then want to do `${foo##*.}`

parent pathikrit 3 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton