{"id":13513491,"url":"https://github.com/f-laurens/pynab_cli","last_synced_at":"2025-03-31T02:32:23.664Z","repository":{"id":52410035,"uuid":"277107795","full_name":"f-laurens/pynab_cli","owner":"f-laurens","description":"Command line tools for Nabaztag rabbits running Pynab","archived":false,"fork":false,"pushed_at":"2022-11-21T14:26:56.000Z","size":86,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-08-02T05:08:19.417Z","etag":null,"topics":["dietpi","nabaztag","pynab","raspberry-pi","raspbian","tagtagtag"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/f-laurens.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-04T12:42:39.000Z","updated_at":"2024-06-12T17:08:30.000Z","dependencies_parsed_at":"2023-01-22T04:15:36.713Z","dependency_job_id":null,"html_url":"https://github.com/f-laurens/pynab_cli","commit_stats":null,"previous_names":[],"tags_count":26,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f-laurens%2Fpynab_cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f-laurens%2Fpynab_cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f-laurens%2Fpynab_cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f-laurens%2Fpynab_cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/f-laurens","download_url":"https://codeload.github.com/f-laurens/pynab_cli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":222615145,"owners_count":17012022,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dietpi","nabaztag","pynab","raspberry-pi","raspbian","tagtagtag"],"created_at":"2024-08-01T05:00:29.002Z","updated_at":"2024-11-01T17:30:24.779Z","avatar_url":"https://github.com/f-laurens.png","language":"Shell","funding_links":[],"categories":["Shell","Outils"],"sub_categories":[],"readme":"# [pynab_cli](https://github.com/f-laurens/pynab_cli/archive/release.zip)\n\nA collection of small command line tools for [Pynab](https://github.com/nabaztag2018/pynab)-running Nabaztag rabbits that have been revived using the [Raspberry Pi Zero W](https://www.raspberrypi.org/products/raspberry-pi-zero-w)-powered [Tag:tag:tag](https://www.tagtagtag.fr/index_eng.html) card.\n\n## nabaztag\n\nA script to send packets to the rabbit's nabd daemon, according to the [Pynab protocol](https://github.com/nabaztag2018/pynab/blob/master/PROTOCOL.md).\n\n\t\tpi@Nabaztag:~ $ nabaztag -h\n\t\tUsage: nabaztag [-g | -e | -l | -m | -s | -w | -p LEFT.RIGHT | -r | -v | -c COMMANDFILE] [HOST]\n\t\t\tTalk to rabbit HOST (default: localhost)\n\t\t\t no option :\tget state\n\t\t\t\t-h :\tthis usage help\n\t\t\t\t-g :\tget gestalt status\n\t\t\t\t-e :\texecute ears test\n\t\t\t\t-l :\texecute LEDs test\n\t\t\t\t-m :\tmonitor asr/button/ears/rfid events\n\t\t\t\t-s :\tgo to sleep\n\t\t\t\t-w :\twake up\n\t\t\t\t-p :\trotate ears to position LEFT.RIGHT\n\t\t\t\t-r :\trotate ears to random position\n\t\t\t\t-v :\tdisplay virtual rabbit (running in Docker on HOST)\n\t\t\t\t-c :\texecute given JSON COMMANDFILE\n\t\t\t\nExamples of JSON command files are provided in the `json` directory.  \nThis script should be usable on a non-rabbit OS, if it provides the `nc` (`netcat`) command.\n\n**Note:**  \nTalking to a remote rabbit is possible only if the nabd socket on this rabbit has been enabled for public access.\n\n## tagtagtag-sound\n\nA script to get/set the rabbit's Tag:tag:tag sound card low/high volume levels.\n\n\t\tpi@Nabaztag:~ $ tagtagtag-sound -h\n\t\tUsage: tagtagtag-sound [-t | -T] [-m low | -M high] [-p]\n\t\t\t no option :\tget sound volume levels\n\t\t\t\t-h :\tthis usage help\n\t\t\t\t-t :\thandle volume for Nabaztag\n\t\t\t\t-T :\thandle volume for Nabaztag:tag (default)\n\t\t\t\t-m :\tset minimum volume level\n\t\t\t\t-M :\tset maximum volume level\n\t\t\t\t-p :\tpatch/unpatch ADC mixer (to eliminate NFC card interference)\n\n## backup/restore_pynab_db\n\nScripts to backup and restore the rabbit's Pynab PostgreSQL database.\n\n\t\tpi@Nabaztag:~ $ backup_pynab_db -h\n\t\tUsage: backup_pynab_db [-u DB_USER] [-d DB_NAME] [-b DB_BACKUP_FILE]\n\t\t\tBackup (as user DB_USER) PostgreSQL database DB_NAME to file DB_BACKUP_FILE\n\t\t\tdefaults: DB_USER=postgres DB_NAME=pynab DB_BACKUP_FILE=pynab.db.sql\n\t\t\n\t\tpi@Nabaztag:~ $ restore_pynab_db -h\n\t\tUsage: restore_pynab_db [-u DB_USER] [-b DB_BACKUP_FILE]\n\t\t\tRestore (as user DB_USER) PostgreSQL database from file DB_BACKUP_FILE\n\t\t\tdefaults: DB_USER=postgres DB_BACKUP_FILE=pynab.db.sql\n\n**Note:**  \nBackup can be done on the fly (while the rabbit's Pynab services are running). According to PostgreSQL documentation, the backup is consistent (based on a 'snapshot' of the database).  \nOn the other hand restore must be done without concurrent accesses to the database (so that it can be re-created). Pynab services must therefore be stopped beforehand and restarted after the backup (the script takes care of this).\n\n## pynab\n\nA script to manage Pynab services.\n\t\t\n\t\tpi@Nabaztag:~ $ pynab -h\n\t\tUsage: pynab [-status | -start | -stop | -restart | -local | -public | -log [NUM]]\n\t\t\tno option :\tshow status of Pynab services\n\t\t\t    -help :\tthis usage help\n\t\t\t   -start :\tstart Pynab services\n\t\t\t    -stop :\tstop Pynab services\n\t\t\t -restart :\trestart Pynab services\n\t\t\t  -status :\tshow status of Pynab services\n\t\t\t   -local :\trestrict nabd socket to local access\n\t\t\t  -public :\topen nabd socket to public access\n\t\t\t     -log :\tshow log tails (last NUM lines) for Pynab daemons\n\n**Note:**  \nBy default, rabbit's nabd socket is restricted to local access (from the rabbit itself).  \nOpening it to public access makes it accessible from other hosts. This is a **potential security risk** if the rabbit is not on a local network protected by a firewall.\n\n## Miscellaneous administration\n\nA collection of wrapper scripts for Pynab development \u0026 administration:\n- update_pynab_messages\n\n\t\tpi@Bunny:~ $ update_pynab_messages -h\n\t\tUsage: update_pynab_messages [-m] [-c] [MODULE...]\n\t\t\tMake (if -m) and Compile (if -c) localisation messages for Pynab modules MODULE...\n\t\t\tdefaults: MODULES='nab?*d nabweb'\n- migrate_pynab_models\n\n\t\tpi@Bunny:~ $ migrate_pynab_models -h\n\t\tUsage: migrate_pynab_models [-c] [-m]\n\t\t\tCreate new (if -c) and Execute (if -m) Pynab data models migrations\n- django_admin_pynab\n\n\t\tpi@Bunny:~ $ django_admin_pynab  -h\n\t\tUsage: django_admin_pynab [COMMAND ARGS...]\n\t\t\tExecute django-admin script for Pynab\n- rebuild_pynab_drivers\n\n\t\tpi@Bunny:~ $ rebuild_pynab_drivers -h\n\t\tUsage: rebuild_pynab_drivers [-f]\n\t\t\tRebuild (if -f) TagTagTag drivers for Pynab\n- upgrade_pynab\n\n\t\tpi@Bunny:~ $ upgrade_pynab -h\n\t\tUsage: upgrade_pynab [-u]\n\t\t\tRun (if -u) Pynab upgrade script\n- install_pynab\n\n\t\tpi@Bunny:~ $ install_pynab -h\n\t\tUsage: install_pynab [-i] [-u]\n\t\t\tRun (if -i) Pynab install script (in upgrade mode if -u)\n- check_pynab_syntax\n\n\t\tpi@Bunny:~ $ check_pynab_syntax -h\n\t\tUsage: check_pynab_syntax [-b] [-p] [-f] [-i] [MODULE...]\n\t\t\tRun Python syntax checkers on Pynab modules MODULE...\n\t\t\t-b : run black   -p : run pycodestyle   -f : run flake8   -i : run isort\n\t\t\tdefaults: MODULES='nabcommon nabboot nabd nab?*d nabweb'\n- pytest_pynab\n\n\t\tpi@Bunny:~ $ pytest_pynab -h\n\t\tUsage: pytest_pynab\n\t\t\tRun pytest unit tests for Pynab\n\n**Note:**  \nThese should be used with caution (**only knowingly**).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff-laurens%2Fpynab_cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ff-laurens%2Fpynab_cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff-laurens%2Fpynab_cli/lists"}