Post #2176273
2026-02-23 00:02 UTC
What does your ~/.bashrc look like? My last change was modifying a `playlist` command
::: spoiler spoiler: I explain my last change to my ~/.bashrc file
```bash
playlist https://www.youtube.com/@YouTube/videos
```
or
```bash
playlist /home/username/Videos
```
or just from any directory with files
```bash
playlist
```
And then takes all the videos found at the url or at the path (including within folders), adds them to a playlist, shuffles them, and plays them from mpv.


```bash
playlist() {
param=""
# If the first parameter has a length more than 1 character
if [ ${#1} -gt 1 ]; then
param="${@}"
else
param="."
fi
screen mpv $param --shuffle --ytdl-raw-options-add=cookies-from-browser=firefox --loop-playlist=inf --no-keepaspect-window --no-auto-window-resize
}
```
:::
::: spoiler other functions and aliases in my ~/.bashrc
```bash
alias code=codium
alias files=nautilus
alias explorer=nautilus
alias rust="/path/to/.cargo/bin/evcxr"
alias sniffnet="export ICED_BACKEND=tiny-skia; /path/to/.cargo/bin/sniffnet"
alias http-server='/path/to/.cargo/bin/miniserve'
alias iphone='uxplay'
alias airplay='uxplay'
alias watch='screen mpv --ytdl-raw-options-add=remote-components=ejs:github --ytdl-raw-options-add=cookies-from-browser=firefox --no-keepaspect-window '
alias twitch='watch'
alias timeshift-launcher="pkexec env WAYLAND_DISPLAY='$WAYLAND_DISPLAY' XDG_RUNTIME_DIR='$XDG_RUNTIME_DIR' /usr/bin/timeshift-launcher"
alias update="sudo apt update && sudo apt upgrade -y && sudo flatpak update -y && sudo snap refresh"
alias resize="path/to/resize/videos/resize.sh"
playlist() {
param=""
# If the first parameter has a length more than 1 character
if [ ${#1} -gt 1 ]; then
param="${@}"
else
param="."
fi
screen mpv $param --shuffle --ytdl-raw-options-add=cookies-from-browser=firefox --loop-playlist=inf --no-keepaspect-window --no-auto-window-resize
}
gif() { ffmpeg -i $1 -f yuv4mpegpipe - | gifski -o $2 ${@:3} -;}
```
:::
Replies (1)
-
@db2@lemmy.world 2026-02-23 04:22
I wonder if we have the same resize.sh