Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
1 vote
1 answer
107 views

Parse a selection of date formats

This Bash program parses day, month, year and month and year from arguments: ...
craig's user avatar
  • 235
2 votes
1 answer
108 views

Bash time converter

This is a simple script to convert a given unit of time to other units of time. I wrote this mainly to practice writing scripts that incorporate positional parameters. It actually turned out better ...
I0_ol's user avatar
  • 453
4 votes
2 answers
99 views

Create and open a file to take lecture notes depending on day and time

I am just wondering what, if any, more elegant ways might exist to write a script to accomplish the task that the script below accomplishes. The script works, so I don't need it to be debugged, but I ...
dlk0606's user avatar
  • 43
1 vote
2 answers
254 views

Iterating over a range of dates in a shell script

I have been working on a script that can be used to automatically pull the batch ids that were processed 4 days ago and which need to be processed tomorrow on the server. The batch IDs from 3 days ago ...
Amit Alone's user avatar
4 votes
1 answer
600 views

Adding multiple events in gcalcli using a bash script

...
Dyslexic's user avatar
5 votes
1 answer
91 views

Customized date and time display

A simple reworking of the Bash date command to my own personal liking. Possibly a rather trivial task; I just wanted the date and time to be in the form of: ...
I0_ol's user avatar
  • 453
6 votes
3 answers
229 views

Checking and converting [[HH:]MM:]SS input format

I would like to use the following routine in my job submission bash script which expects the allowed walltime in the format [[HH:]MM:]SS. (Brackets indicating ...
Martin - マーチン's user avatar
3 votes
2 answers
72 views

Return the first number found greater than the provided input number (13 digits)

This script converts the numbers to be at least 13 characters long (for UNIX_MS strings). For use with timestamps, I'm having issues with it being very slow. I wanted an alternative to grepping for ...
buddyp450's user avatar
  • 139
4 votes
3 answers
110 views

Checking dates against a .properties file

I am writing a script that will check the set values against a .properties file and I am just wondering if there is any nicer way to write what I have here. ...
ClarkPamler93's user avatar
4 votes
3 answers
1k views

Loop through all virtualhost log files and run goaccess on each file

So I have multiple websites running under apache2 virtualhost - and I wanted to use GoAccess to process the access.log for each site. The directory structure is ...
DannyTheDev's user avatar
3 votes
1 answer
155 views

Changing cuts to sed for parsing dates from apache log (common log file)

Would switching my cuts below to SED improve performance? I am trying to get a per date count of requests for the last two weeks from a server log. The script runs, but slowly (comes in around 14 ...
Marc K's user avatar
  • 133