Skip to content

Instantly share code, notes, and snippets.

Avatar
🐧
Art, engineering & digital training

Yoan Mollard ymollard

🐧
Art, engineering & digital training
  • Bordeaux INP
  • Bordeaux, France
View GitHub Profile
View gist:f953ca7e797d0ea114c69ce0dd20e9d4
File "/usr/share/system-config-printer/printerproperties.py", line 1425, in load
option.reinit (value, supported=supported)
File "/usr/share/system-config-printer/options.py", line 229, in reinit
self.set_widget_value (self.original_value)
File "/usr/share/system-config-printer/options.py", line 257, in set_widget_value
index = self.combobox_map.index (ipp_value)
ValueError: 0 is not in list
@ymollard
ymollard / android-frontage.bash
Last active Dec 15, 2020
Build frontage-frontend
View android-frontage.bash
sudo apt install openjdk-8-jdk google-android-platform-24-installer
sudo update-alternatives --config java # Select Java 8
sudo update-alternatives --config javac # Select Java 8
export ANDROID_SDK_ROOT=/home/$USER/Android/Sdk
# JAVA_HOME/ANDROID_HOME are not needed
ionic cordova prepare android
ionic cordova run android --device
View count_files_by_extension.bash
find -type f | rev | cut -d. -f 1 | rev | sort | uniq -c | sort -n
@ymollard
ymollard / mount_img.md
Created Oct 31, 2020
Mount an img file with multiple partitions to edit files in them
View mount_img.md
sudo losetup 2020-10-23-poppy-torso.img -Pf
ll /dev/loop*

Then find the partition there eg /dev/loop15p2

mdkir -p mnt
@ymollard
ymollard / multipass.md
Last active Feb 4, 2021
Multipass VMs
View multipass.md

Build a custom image

multipass launch           # will create a 20.04
sudo apt update
sudo apt upgrade
sudo apt install ubuntu-desktop xrdp
sudo passwd ubuntu         # Change the password
View scratch_build.md

https://github.com/LLK/scratch-gui/wiki/Getting-Started#example-scratch-gui-vm-and-blocks-linked

mkdir scratch && cd scratch
git clone https://github.com/aubrune/scratch-gui # if making changes fork the project and check out your copy
git clone https://github.com/aubrune/scratch-vm # if making changes fork the project and check out your copy
git clone https://github.com/aubrune/scratch-blocks # if making changes fork the project and check out your copy
cd scratch-vm
npm install
sudo npm link
View build_ios.bash
git clone git clone https://github.com/arbalet-project/frontage-frontend.git -b ionic_5
cd frontage-frontend
npm i
ionic build
# Generate assets with cordova
ionic capacitor open ios # Close Xcode then
npm install -g cordova-res
cordova-res ios
wget https://gist.githubusercontent.com/dalezak/a6b1de39091f4ace220695d72717ac71/raw/3c858045b84dab9d39bd53cb2d19fba3e523bef4/resources.js
@ymollard
ymollard / config.json
Created Sep 26, 2020 — forked from EtienneSchmitz/config.json
Frontage/Bordeaux
View config.json
{
"apps": [
"Flags",
"RandomFlashing",
"SweepRand",
"SweepAsync",
"Tetris",
"Snake",
"Drawing"
],
View config_capsciences.json
{
"apps": [
"Flags",
"RandomFlashing",
"SweepRand",
"SweepAsync",
"Tetris",
"Snake",
"Drawing"
],
@ymollard
ymollard / to_pypi.bash
Created Aug 28, 2020
Create tags to trigger publishing to Pypi
View to_pypi.bash
git commit -am "Version bump"
git push origin master
git tag 4.0.3
git push 4.0.3