Skip to content

Commit f7ee728

Browse files
authored
Merge pull request #21 from kfsone/dev/add-month3
v0.0.6: add ${month3}
2 parents bfab099 + 866c2ec commit f7ee728

3 files changed

Lines changed: 8 additions & 4 deletions

File tree

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This extension allow you to insert timestamp, copyright or any information to yo
1010

1111
## Features
1212

13-
- insert defined parameter like `date`, `time`, `datetime`, `day`, `month`, `year`, `hour`, `minute`, `second`, `company`, `filename`
13+
- insert defined parameter like `date`, `time`, `datetime`, `day`, `month`, `month3`, `year`, `hour`, `minute`, `second`, `company`, `filename`
1414
- insert your own parameter and template
1515
- define multiple templates
1616

@@ -127,6 +127,7 @@ You can use parameters below in your template
127127
- `company` : print "Your Company"
128128
- `day`: print day of the month
129129
- `month`: print current month
130+
- `month3`: first-3 letters of the month, e.g "Mar"
130131
- `year`: print current year
131132
- `hour`: print current hour (24h)
132133
- `minute`: print current minute
@@ -136,6 +137,8 @@ You can use parameters below in your template
136137

137138

138139
## Release Notes
140+
### 0.0.6
141+
- add month3 (thanks to @kfsone)
139142
### 0.0.5
140143
- fixing python comment style (thanks to @ronak1009)
141144
### 0.0.4
@@ -151,4 +154,4 @@ You can use parameters below in your template
151154

152155
### 0.0.1
153156

154-
- Initial release
157+
- Initial release

command.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ function insertFileHeaderComment(picked_template){
6666
'time24h': h+':'+m+':'+s,
6767
'day': date.getDate(),
6868
'month': date.getMonth()+1,
69+
'month3': date.toLocaleString('en-us', {month:'short'}),
6970
'year': date.getFullYear(),
7071
'company': 'Your Company',
7172
'filename': vscode.window.activeTextEditor.document.fileName.replace(/^.*[\\\/]/, ''),

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "fileheadercomment",
33
"displayName": "File Header Comment",
44
"description": "Insert File Header Comment such as date, time",
5-
"version": "0.0.5",
5+
"version": "0.0.6",
66
"publisher": "doi",
77
"engines": {
88
"vscode": "^1.0.0"
@@ -56,4 +56,4 @@
5656
"url": "https://github.com/doi/fileheadercomment/issues"
5757
},
5858
"license": "SEE LICENSE IN LICENSE.md"
59-
}
59+
}

0 commit comments

Comments
 (0)