A CLI to generate a certificate when going out in France during the COVID-19 pandemic.
Filling web forms might be boring (especially for developers!!) when going outside during the pandemic by using the official website. This CLI will provide you with your certificate (aka, ATTESTATION DE DÉPLACEMENT DÉROGATOIRE) in one click! However, once generated, you have to figure out how to copy to your mobile device :D
The generated PDF file matches exactly the one generated by the official website as it uses the same code!
Original repository: https://github.com/LAB-MI/deplacement-covid-19
The code is written in JavaScript, thus, NodeJS is needed.
Download the required packages for the project
npm i
First, the profile.json has to be filled with the required information.
{
"lastname": "Times",
"firstname": "Vincent",
"birthday": "30/02/2000",
"lieunaissance": "Namportou",
"address": "1 rue du grand rue",
"zipcode": "99000",
"town": "Mille ans"
}
Then, simply run the script while specifying the reason for going out:
node certificate.js 'sport'
The current date and time will be used by default, however, they could be also specified:
node certificate.js 'sport' --time="17h00"
node certificate.js 'sport' --time="05h55" --date="20/02/2020"
Multiple reasons can be included separated by a dash '-'
(or any other character, or even NULL):
node certificate.js 'courses-sport' --time="17h00"
With custom profile and output files:
node certificate.js 'famille' --profile=my-grandma-profile.json --output=attestation-grandma.pdf
Show help message and possible reasons
node certificate.js -h