Я ищу функцию bash, которая сократит длинные имена путей, чтобы моя переменная PS1 не становилась слишком длинной. Что-то вроде:
/this/is/the/path/to/a/really/long/directory/i/would/like/shortened
может закончиться следующим образом:
/t../i../t../p../to/a/r../l../d../i/w../like/shortened
что-то, что взял путь и максимально допустимое количество символов для сокращения, было бы идеально для моего .bashrc файла.