modules installed from a module registry, such as the Public OpenTofu Registry or any TACOS (TF Automation and Collaboration Software) private modules registry. Other module sources can provide their own versioning mechanisms within the source string itself, or might not support versions at all. In particular, modules sourced from local file paths do not support version; since they're loaded from the same source repository, they always share the same version as their caller.
Un petit script pour check si les modules ont de nouvelles version dispo (il faut jq)
#!/bin/bash
modules=$(puppet module list|grep '\(v[0-9]\.[0-9]\.[0-9]\)')
IFS=$'\n'
for line in $modules; do
name=$(echo $line|cut -d' ' -f2)
version=$(echo $line|grep -o '\(v[0-9]\.[0-9]\.[0-9]\)'|sed 's/v//')
current_version=$(curl -s https://forgeapi.puppetlabs.com/v3/modules/${name}|jq '.current_release.version'|sed 's/"//g')
if [[ $version == $current_version ]]; then
echo "OK $name $version $current_version"
else
echo "OUTDATED $name $version $current_version"
fi
done
Des modules qui ont l'air bien
Objectif : tapper /obug dans xchat m'ouvre un onglet dans ff vers l'url du bug
1) activer le module python dans les options
2) créer un fichier .py dans /home/arnaud/.xchat2/
3)
module_name = "openbuginredmine"
module_version = "1.0"
module_description = "module to open bug in redmine"
import os
import xchat
def obug(word, word_eol, userdata):
if len(word) < 2:
print "Second arg must be the bug number!"
else:
#xchat.command("NOTICE @%s %s" % (xchat.get_info("channel"), word_eol[1]))
os.system("firefox https://monurlredmine.com/issues/"+word[1])
return xchat.EAT_ALL
xchat.hook_command("obug", obug, help="/obug open bug in ff")
Et voilà, plus qu'à reboot le xchat, ou bien /load nomdufichier.py
ça peut etre appliqué à plein de trucs : pouvoir lancer ce qu'on veut depuis xchat
Comment écrire un module très basique chargeable/déchargeable (insmod/rmmod) pour le noyau de linux