Blog: 2023-07-18: Difference between revisions
No edit summary |
No edit summary |
||
(2 intermediate revisions by the same user not shown) | |||
Line 16: | Line 16: | ||
Thinking about recursive git clones. also how some command line tools are pretty much like functions, and how therefore a programming environment could be built up function by function rather than pulling in a huge package like python. But batteries included makes for a lot of ease |
Thinking about recursive git clones. also how some command line tools are pretty much like functions, and how therefore a programming environment could be built up function by function rather than pulling in a huge package like python. But batteries included makes for a lot of ease |
||
After struggling a bit with trying to display from a line of a file to the end (in this case "Description:" to match <code>apt show</code>) I was reminded of a terminal feature I heard of, where it would automatically page outputs such that you'd see the first lines of output from a command, or the whole output if it fit on a screen. I think that was a plan 9 feature. Ended up going with a 2-part command - use grep to find the start line, then use tail to start from that line, to the end |
|||
This process was made much more cumbersome by having multiple package versions report their info... I'd like <coded>apt show</code> to only show the installed version (are multiple versions installed for these packages?) |
|||
Now I'm thinking about a package manager that has a stable command line output (or doesn't, I don't really care - maybe even going a step further it would use powershell style structured output) and has commands that map more to what I picture: |
|||
* install |
|||
* upgrade |
|||
* update (brew does this for every command) |
|||
* description |
|||
* summary / show |
Latest revision as of 17:56, 18 July 2023
List installed debian packages by size
dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -n
But what are the units here? kilobytes? probably. But would be nice to have units. Powershell style structured output could be useful here.
Nice browser of installed packages: dpkg --list
Journalctl shows all messages you can see by default: journalctl
Tail messages with journalctl with -f for follow:
journalctl -f
Thinking about recursive git clones. also how some command line tools are pretty much like functions, and how therefore a programming environment could be built up function by function rather than pulling in a huge package like python. But batteries included makes for a lot of ease
After struggling a bit with trying to display from a line of a file to the end (in this case "Description:" to match apt show
) I was reminded of a terminal feature I heard of, where it would automatically page outputs such that you'd see the first lines of output from a command, or the whole output if it fit on a screen. I think that was a plan 9 feature. Ended up going with a 2-part command - use grep to find the start line, then use tail to start from that line, to the end
This process was made much more cumbersome by having multiple package versions report their info... I'd like <coded>apt show to only show the installed version (are multiple versions installed for these packages?)
Now I'm thinking about a package manager that has a stable command line output (or doesn't, I don't really care - maybe even going a step further it would use powershell style structured output) and has commands that map more to what I picture:
- install
- upgrade
- update (brew does this for every command)
- description
- summary / show