argentnoelle: purple tree (Default)
[personal profile] argentnoelle
that i've never done before. I know some html, don't really know css but can make it do stuff for me, but for the first time I messed around in terminal & managed to find file directories and make it list out files that I have. I know, it's super basic lol :) but it was cool to see stuff happen when I typed! ah, not even list files in directories, I also got it to tell me when the files were created. Awesome.
Let's see if I can remember what the commands were:

cd [finding certain folders through paths]
ls [list]
ls -l [that's an L] [for showing the date created etc]
yay!

also figured out a small little issue that was confusing me for a bit. For a while I was having trouble where the path wasn't working, say

/folder1/folder2/folder 3

it was like "never heard of that place."

Then I managed to google & find out that, of course, it was getting all tripped up by the space. Of course! why would it think those were the same thing? I know it because I know what I named my folders but the computer doesn't. A folder with a space in the name has to be written like this:

/folder 1/folder2/"folder 3"

kind of self-evident. But also. cool! I figured it out :)

Date: 2022-12-03 05:14 am (UTC)
mindstalk: Tohsaka Rin (Rin)
From: [personal profile] mindstalk
Congrats! I remember messing around with a DOS computer and manuals, and going from "magic command makes Pascal happen" to "ooh, there's a shell waiting for strings, and lots of the commands are just files on the disk and I can _see_ them."

The space-in-filename thing and "the computer" is a bit tricky. Under the hood, lots of functions for dealing with filenames are just fine with it containing a space. But you're not a programmer calling functions, you're a user interacting with one specific computer program, the shell (probably /bin/bash if default Linux or /bin/zsh if a Mac), and _it_ expects spaces separating all the interesting units in the commands you give it. Thus the need to quote names with spaces in them. Likewise, ? and * are treated specially by the shell, so a command like 'curl http://foo.com?name=Alice' needs to be 'curl "http://foo.com?name=Alice"' to keep the shell from trying to do something with the ?.

Also useful exploration:

man ls -- 'manual page' for the ls command. Most other file commands have man pages too. Commands built into the shell may not.
set -- by itself, dumps out all the environment variables. 'set | more' or 'set | less' more useful for seeing them all.

Profile

argentnoelle: purple tree (Default)
ArgentNoelle

November 2023

S M T W T F S
   1234
567891011
12131415161718
19202122232425
2627282930  

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Mar. 12th, 2026 02:52 am
Powered by Dreamwidth Studios