Advertisement
metalx1000

Display an image next to text in your terminal

Jan 19th, 2025
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.38 KB | None | 0 0
  1. # install chafa for ascii art
  2. sudo apt install chafa
  3.  
  4. # get example image and text
  5. wget -c "https://filmsbykris.com/v7/img/tux.png"
  6. wget -c "https://filmsbykris.com/scripts/2025/ipsum.txt"
  7.  
  8. # Convert image to ascii/unicode text
  9. chafa tux.png > tux.txt
  10.  
  11. # print text file with a max of 40 characters width
  12. # and place image text next to it
  13. fold -w 40 -s ipsum.txt|paste tux.txt -
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement