<commit_before>Imaging the SD card
-------------------
Connect the card to your computer.  
Run the following command to locate the device name.

    $ df -h
    ...
    /dev/sdx0       1.3G  831M  362M  70% /media/xxx
    ...

Locate the one mounted under media, where x is a letter and 0 a number.  
Double check the device size just to make sure.

Run the following commands.

    $ umount /dev/sdx0
    $ sudo dd bs=4M if=2015-11-21-raspbian-jessie-lite.img of=/dev/sdx
    $ sync

Insert the card into the pi and connect its network cable.  
Time to boot.

Figuring out the pi's IP address
--------------------------------
Still connected to your computer, run the following command.

    $ ip addr
    ...
    3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    ...

Locate the name of you connected network interface.  
Run the following command.

    $ sudo arp-scan --interface=wlan0 --localnet
    ...
    192.168.1.102   b8:27:eb:cb:c2:cf       (Unknown)
    ...

Get the IP address on the line displaying b8:27.  
This is the pi's address on your network.

Connecting to the pi
--------------------
Run the following commands.

    $ ssh pi@192.168.1.102
    password: <PASSWORD>

    $ adduser mathieu
    $ adduser mathieu sudo

    $ exit

Now reconnect as yourself and run the following commands.

    $ ssh mathieu@192.168.1.102

    $ sudo deluser -remove-home pi
    $ sudo groupdel pi

Upgrading the OS
----------------
Run the following commands.
<commit_msg>First draft at raspberry pi web werver<commit_after>Imaging the SD card
-------------------
Connect the card to your computer.  
Run the following command to locate its device name.

    $ df -h
    ...
    /dev/sdx0       1.3G  831M  362M  70% /media/xxx
    ...

Get the one mounted under media, where x is a letter and 0 a number.  
Double check the device size just to make sure.

Run the following commands.

    $ umount /dev/sdx0
    $ sudo dd bs=4M if=2015-11-21-raspbian-jessie-lite.img of=/dev/sdx
    $ sync

Insert the card into the pi and connect its network cable.  
Time for a first boot.

Figuring out the pi's IP address
--------------------------------
Still connected to your computer, run the following command.

    $ ip addr
    ...
    3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    ...

Locate the name of your connected network interface.  
Run the following command.

    $ sudo arp-scan --interface=wlan0 --localnet
    ...
    192.168.1.102   b8:27:eb:cb:c2:cf       (Unknown)
    ...

Get the IP address on the line showing b8:27.  
This is the pi's address on your network.

Connecting to the pi
--------------------
Run the following commands.

    $ ssh pi@192.168.1.102
    password: <PASSWORD>

    $ adduser mathieu
    $ adduser mathieu sudo

    $ exit

Now reconnect as yourself and run the following commands.

    $ ssh mathieu@192.168.1.102

    $ sudo deluser -remove-home pi
    $ sudo groupdel pi

Upgrading the OS
----------------
Run the following commands.

{'fraction_non_alphanumeric': 0.1277975997405125, 'fraction_numerical': 0.0454103146286085, 'mean_word_length': 2.0686567164179106, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 6, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4212732', 'n_tokens_mistral': 1074, 'n_tokens_neox': 945, 'n_words': 380}