256 Kilobytes

All Content > BASH

Type All Category All Tag BASH

Profile Photo - August R. Garcia

Generating Fake Reddit Comments with Markov Chains

Articles in Scripting and Automation | By August R. Garcia

Published 3 weeks agoThu, 28 Feb 2019 16:31:18 -0800 | Last update 3 weeks agoThu, 28 Feb 2019 17:23:39 -0800

Profile Photo - Some Guy

Last Reply Yeah that should be doable. The only thing would be that you would have to make sure those KWs are in the word_dict so that there are pairs to generat... Some Guy,

Yeah that should be doabl...

Tue, 05 Mar 2019 01:25:03 -0800 2 weeks ago
🗨
4
🐏
1
👁
146
Profile Photo - Some Guy

How can I bulk rename files from the Linux terminal?

Answers in Shell Scripting | By Some Guy

Published 1 month agoSun, 10 Feb 2019 23:12:04 -0800 | Last update 1 month agoSun, 10 Feb 2019 23:19:39 -0800

Profile Photo - August R. Garcia

Last Reply Try the rename command. Syntax: Basic syntax: rename (option) 's/oldname/newname/' file1.txt file2.txt Test a rename regex on all file... August R. Garcia,

Try the rename command. S...

Sun, 10 Feb 2019 23:19:24 -0800 1 month ago
🗨
1
🐏
0
👁
60
Profile Photo - Some Guy

What is $1 in Bash/Linux?

Answers in Shell Scripting | By Some Guy

Published 2 months agoSun, 13 Jan 2019 04:14:54 -0800

Profile Photo - roxblade

Last Reply These are basically positional parameters. They are invoked by shell's arguments. So, a simple script like ./code.sh Hi there will make three position... roxblade,

These are basically posit...

Mon, 04 Feb 2019 11:18:58 -0800 1 month ago
🗨
1
🐏
0
👁
55
Profile Photo - Some Guy

Fix for "-Bash: syntax error near unexpected token `newline'?"

Answers in Shell Scripting | By Some Guy

Published 2 months agoSun, 13 Jan 2019 04:19:04 -0800

Profile Photo - roxblade

Last Reply The general explanation behind this error is that instead of a file or resource, the command downloaded an HTML doc or a webpage. Now, based on the en... roxblade,

The general explanation b...

Sun, 03 Feb 2019 13:17:32 -0800 1 month ago
🗨
1
🐏
0
👁
75
Profile Photo - Some Guy
Profile Photo - Some Guy

MoreI am working on scripts on a new app that I am developing. I have question regarding command-prom
🗨
0
🐏
0
👁
25
Profile Photo - Some Guy

How to read a Linux Bash file line by line?

Answers in Operating Systems | By Some Guy

Published 3 months agoSun, 16 Dec 2018 09:36:41 -0800

Profile Photo - Some Guy

What is the simplest way to read line by...

MoreWhat is the simplest way to read line by line in a Linux Bash file?
🗨
0
🐏
0
👁
24
Profile Photo - Some Guy

How can I monitor my GPU usage on Ubuntu?

Answers in Scripting and Automation | By Some Guy

Published 3 months agoSun, 02 Dec 2018 03:42:57 -0800

Profile Photo - August R. Garcia

Last Reply If there is no usable/relevant GUI, this can also be done from the terminal with a looping BASH script like this: # Monitor GPU stats and usage... August R. Garcia,

If there is no usable/rel...

Sun, 02 Dec 2018 03:46:56 -0800 3 months ago
🗨
1
🐏
0
👁
32
Profile Photo - Some Guy

I downloaded a bunch of stock photos for testing. Is there a quick way to bulk rename in Bash (or something similar)?

Forum in Web Scraping, Data Analysis | By Some Guy

Published 3 months agoSun, 02 Dec 2018 03:42:45 -0800 | Last update 3 months agoMon, 03 Dec 2018 06:33:04 -0800

Profile Photo - August R. Garcia

Last Reply A script like run from the terminal or a Bash script works for this type of file renaming: INDEX=1; for i in *.jpg; do mv $i ${INDEX}_cover.jpg;... August R. Garcia,

A script like run from th...

Sun, 02 Dec 2018 03:46:44 -0800 3 months ago
🗨
1
🐏
0
👁
58
Profile Photo - Some Guy

Renaming files from BASH?

Answers in Scripting and Automation | By Some Guy

Published 3 months agoSun, 02 Dec 2018 03:42:23 -0800

Profile Photo - August R. Garcia

Last Reply # Convert clocks subfolders from png to jpgconvert */*.png */*.jpgfor f in $(find */*.png); do echo $f to $f--.jpg convert $f $RANDOM-RANDOM-.jpg r... August R. Garcia,

# Convert clocks subfolde...

Sun, 02 Dec 2018 03:46:22 -0800 3 months ago
🗨
1
🐏
0
👁
23