Compare commits

...

8 Commits

Author SHA1 Message Date
Neel Patel
9d1bcbf6ac Merge 79d446245e into 559d03ecf3 2024-02-27 17:12:24 +08:00
Julien Le Coupanec
559d03ecf3 Merge pull request #372 from cunnellp5/cunnellp/vscode/add-command-and-cleanup-spaces
updates vscode cheat sheet
2024-02-26 18:25:32 +01:00
cunnellp5
bea751612a updates vscode cheat sheet with one command 2024-02-15 07:10:18 -07:00
Julien Le Coupanec
d143c60246 Merge pull request #354 from RomjanHossain/patch-1
swap current line with previous
2023-12-29 15:35:14 +01:00
Romjan D. Hossain
44371217a9 swap current line with previous
it should be `ddkP` instead of `ddkp`
2023-12-24 11:53:04 +06:00
Julien Le Coupanec
d63d75bb28 Merge pull request #350 from adgan11/patch-1
Fix Issue #316: keygen deprecated
2023-11-07 11:40:11 +01:00
Ahmed Gagan
94087440e5 Fix Issue #316: keygen deprecated 2023-11-06 12:16:17 +05:30
Nee Patel
79d446245e Adding a cronjob file 2021-07-08 14:15:04 -04:00
4 changed files with 73 additions and 5 deletions

View File

@@ -185,7 +185,6 @@ width="" <!-- Describes the width of th
<!-- Some other useful tags -->
<canvas></canvas> <!-- Allows to draw 2D shapes on the web page with the help of javascript -->
<keygen> <!-- Represents a control for generating a public-private key pair -->
<map></map> <!-- Specifies an image map -->
<!-- Collective Character Obejcts -->

68
tools/cronjob.txt Normal file
View File

@@ -0,0 +1,68 @@
CRONTAB, is a time-based job scheduler in Unix like operating systems.
In laymen term, it is used to execute scripts on your machine at a predefined time or interval.
This can be any script, for instance downloading images from a particular website every hour or generating a pdf of your unread emails from the past day and the list goes on
###################################
BASICS
###################################
Each line of a crontab represents a job and it looks as follows:
* * * * * command_name
Each asterisk here has a special meaning :
Asterisk 1 : Represents minutes from 0 to 59
Asterisk 2 : Represents hour of the day from 0 to 23
Asterisk 3: Represents day of the month from 1 to 31
Asterisk 4: Represents a month from 1 to 12
Asterisk 5: Represents the day of the week from 0 to 6 (Sunday to Saturday)
Command : A command that executes a script
Example : 0 10 * * * /bin/bash print_time.sh
You can play with these settings from the following site : https://crontab.guru
The above example will execute the script print_time.sh using the /bin/bash shell, everyday at 10:00 A.M. 
Crontab uses a 24 hour clock
Providing the full path to the script is necessary
Providing a shell name or a specific interpreter is necessary too
We can also use the following strings to define job.
@reboot Run once, at startup.
@yearly Run once a year.
@annually (same as @yearly).
@monthly Run once a month.
@weekly Run once a week.
@daily Run once a day.
@midnight (same as @daily).
@hourly Run once an hour.
@reboot <command-to-execute> # run a job every time the system reboots
###################################
CREATING CRONTAB JOBS
###################################
crontab -e # this opens up the crontab file in your predefined editor
# create a basic cronjob that runs everyday at 10:00 A.M.
0 10 * * * /bin/bash ~/Documents/collect_log.sh
- this cronjob will get executed everyday at 10:00 AM
- note the leading 0 is important
- /bin/bash is the interpreter here, and this is required
- ~/Documents/collect_log.sh is the absolute path to the script to be executed
###################################
VIEW CRONJOBS FOR THE CURRENT USER
###################################
crontab -l
##########################################
REMOVE ALL CRONJOBS FOR THE CURRENT USER
##########################################
crontab -r

View File

@@ -105,7 +105,7 @@ gu$ make lowercase until end of line
<< indent line one column to left
== auto-indent current line
ddp swap current line with next
ddkp swap current line with previous
ddkP swap current line with previous
:%retab fix spaces / tabs issues in whole file
:r [name] insert the file [name] below the cursor.
:r !{cmd} execute {cmd} and insert its standard output below the cursor.

View File

@@ -6,7 +6,8 @@
#### General
- `Ctrl`+`Shift`+`P`, `F1`: Show Command Palette
- `Ctrl`+`Shift`+`P`, `F1`: Show Command Palette
- `Ctrl`+`Shift`+`T`: Open last closed tab
- `Ctrl`+`P`: Quick Open, Go to File
- `Ctrl`+`Shift`+`N`: New window/instance
- `Ctrl`+`W`: Close window/instance
@@ -19,7 +20,7 @@
- `Ctrl`+`C`: Copy line (empty selection)
- `Ctrl`+`↓/↑`: Move line down / up
- `Ctrl`+`Shift`+`K`: Delete line
- `Ctrl`+`Enter` / `Ctrl`+`Shift`+`Enter`: Insert line below / above
- `Ctrl`+`Enter` / `Ctrl`+`Shift`+`Enter`: Insert line below / above
- `Ctrl`+`Shift`+`\`: Jump to matching bracket
- `Ctrl`+`]` / `Ctrl`+`[`: Indent / Outdent line
- `Ctrl`+`Home` / `End`: Go to beginning / end of file
@@ -136,7 +137,7 @@
- [`Wrap Console Log`](https://marketplace.visualstudio.com/items?itemName=midnightsyntax.vscode-wrap-console-log): Wrap to console.log by word or selection.
- [`Bracket Pair Colorizer`](https://marketplace.visualstudio.com/items?itemName=CoenraadS.bracket-pair-colorizer): Allows matching brackets to be identified with colours.
- [`Bracket Pair Colorizer`](https://marketplace.visualstudio.com/items?itemName=CoenraadS.bracket-pair-colorizer): Allows matching brackets to be identified with colours.
## My Settings