Git Usage
Export GIT LOG into an CSV File
Go to your GIT repo folder –
In Linux, run
1 | git log --oneline | tr "\r" " > ~/gitlog.csv |
In Windows, run
1 | git log --oneline > c:/temp/gitlog.csv |
GIT also gives your the control on how to format the log output using pretty
option, like below:
1 | git log --pretty=format:%h,%an,%ae,%ad,%s |
Note: --pretty
and --oneline
cannot be used at the same time.
This prints the log in the format of (hash [abbreviated], author name, author email, author date, subject)
To see the full list of format options: git help log
Some more samples:
1 | git log --no-merges --since='mm-dd-yyyy' --pretty=format:%h,%an,%ae,%ad,%s > c:\dev\history.csv |
You can also quote the values directly in the format -
1 | git log --pretty=format:'"%h","%an","%ae","%ad","%s"' --date=iso-strict |
so it’s clear when there’re commas in the memo
Azure DevOps Usage - Get query ID
Whether you create a new query, or use an existing one, you will need to obtain the GUID for this query so that it can be used from inside the Power BI query or Power Apps Canvas.
This can be retrieved from the ADO API by executing the following request in a browser, or HTTP Client (e.g. Postman):
1 | https://[instance-name].visualstudio.com/DefaultCollection/[project-name]/_apis/wit/queries/[path-to-query] |
Where:
- [instance-name] is the ADO instance name, or Organization name
- [project-name] is the AOD project name
- [path-to-query] is the path to the query e.g. “Shared Queries/Current Sprint/Product Backlog”
e.g.
1 | https://endjin.visualstudio.com/DefaultCollection/PowerBI/_apis/wit/queries/Shared Queries/Current Sprint/Product Backlog/ |
The response will be in a format which the first “id” value is the GUID you can use.
info-hexo
HEXO - the Blog tool
[toc]
Base info and Installation
Website: https://hexo.io
Documentation: https://hexo.io/docs
Requirements of Installation:
- Node.js
- Git:
sudo apt install git-core
Installation:
1 | $ sudo npm install hexo-cli -g |
After the above command, you should be able to see:
1 | INFO Validating config |
Using HEXO
Command: init
$ hexo init [folder]
This command initializes a website. If no folder
is provided, Hexo will set up a website in the current directory.
Command: new
$ hexo new [layout] <title>
Create a new article. If no layout
is provided, Hexo will use the default_layout
from __config.yml. If the title
contains spaces, surround it with quotation marks.
Options includes
-p
,--path
: Post path. Customize the path of the post.-r
,--replace
: Replace the current post if existed.-s
,--slug
: Post slug. Customize the URL of the post.
Command: generate
$ hexo generate
Generates stataic files
Options are
-d
,--deploy
: Deploy after generation finishes-w
,--watch
: Watch file changes-b
,--bail
: Raise an error if any unhandled exception is throw during generation-f
,--force
: Force regenerate-c
,--concurrency
: Maximum number of files to be generated in parallel. Default is infinity
Command: deploy
1 | $ hexo deploy |
Hello World
Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.
Quick Start
Create a new post
1 | $ hexo new "My New Post" |
More info: Writing
Run server
1 | $ hexo server |
More info: Server
Generate static files
1 | $ hexo generate |
More info: Generating
Deploy to remote sites
1 | $ hexo deploy |
More info: Deployment