Skip to content

Instantly share code, notes, and snippets.

View antoinetavant's full-sized avatar

Antoine Tavant antoinetavant

View GitHub Profile
@antoinetavant
antoinetavant / GitCommitEmoji.md
Last active November 18, 2020 12:57 — forked from parmentf/GitCommitEmoji.md
Git Commit message Emoji
# Modify your .bashrc with the following
# from https://redandblack.io/blog/2020/bash-prompt-with-updating-time/
DIRECTORY="\w"
DOUBLE_SPACE=" "
NEWLINE="\n"
NO_COLOUR="\e[00m"
PRINTING_OFF="\["
PRINTING_ON="\]"
PROMPT_COLOUR="\e[0;33m"
@antoinetavant
antoinetavant / push_on_pypi.md
Created March 19, 2019 16:07
push a python project on pypi

Port a project on pypi

There is the lists of commands to port a python project on pypi.org. We espect you project to have a correct file setup.py. You also need twine (use pip install twine to install it).

Create a source distribution

with the following command:

python setup.py sdist
@antoinetavant
antoinetavant / script_test_LPPic.sh
Last active September 11, 2023 06:22
script to run in a docker, just to see it it works
echo "pulling LPPic !"
git clone https://tavant@hephaistos.lpp.polytechnique.fr/rhodecode/GIT_REPOSITORIES/LPP/LPPic2D/LPPic
cd LPPic
git checkout FIX_Diel
mkdir -p build
cd build
module load mpi/openmpi-x86_64
export libinfo=SHARED && cmake ..
make -j
@antoinetavant
antoinetavant / docker_steps.md
Created March 19, 2019 10:25
Steps in oder to run a docker

How to launch a docker

There is what's need to be done in order to launch the docker container I need for my these.

Configuration

  • Fedora 29
  • That's all

Install docker if needed

From the docker docs.

@antoinetavant
antoinetavant / gist:79569bf7d4f20ab0e30b26067044518a
Created January 15, 2019 07:22
defet hdf5 files older than 10 minues
find . -type f -name "*.h5" -cmin +10 -exec rm {} \;
@antoinetavant
antoinetavant / gist:8404f79a8f6e98b3658a62c6543567a3
Last active September 10, 2018 11:22
Detect if an executable is compiled with debug option `-g`
#!/usr/bin/env python3
"""This module helps to inspect an executable.
In particulare:
1. If it has been compiled with debug option `_g`
Author: Antoine Tavant, email: antoinetavant <at> hotmail . fr
Summary:
We use and grep the `gdb` call for the presence of the debugging symbols.
Retrun True if the flag `-g` has been used
@antoinetavant
antoinetavant / set_evolution_light_theme.sh
Created August 1, 2018 07:15
Change the default Gnome theme of Evolution to the light theme. This is because I don't like the black theme of evolution, but each update reset the modification.
sudo vim /usr/share/applications/org.gnome.Evolution.desktop -c %s/Exec=/Exec=env GTK_THEME=Adwaita:light /g
@antoinetavant
antoinetavant / fish_shell_local_install.sh
Last active July 3, 2018 08:57 — forked from masih/fish_shell_local_install.sh
Installs Fish Shell without root access
#!/bin/bash
# Script for installing Fish Shell on systems without root access.
# Fish Shell will be installed in $HOME/local/bin.
# It's assumed that wget and a C/C++ compiler are installed.
# exit on error
set -e
FHISH_SHELL_VERSION=2.7.0
@antoinetavant
antoinetavant / DisplaySignature.ipynb
Last active January 11, 2018 16:01
Display a signature as a footer in your Notebook
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.