The C++ crawler walks through a Linux directory tree and records metadata about every discovered file system entry in SQLite. The PHP web application then reads that SQLite database and makes it searchable and browsable.
Think of Tusho as three layers:
Run these commands in order:
./scripts/setup_linux.sh
mkdir -p /tmp/tusho-demo
touch /tmp/tusho-demo/example.txt
./scripts/build.sh --run-tests
./scripts/run_crawler.sh --database-path /tmp/tusho-demo/catalog.sqlite3 --crawl-root /tmp/tusho-demo --log-file-path /tmp/tusho-demo/crawler.jsonl --rebuild-database
./scripts/run_web_application.sh --database-path /tmp/tusho-demo/catalog.sqlite3
Then open http://127.0.0.1:8080/index.php.
./scripts/setup_linux.shUse this first. It installs the Linux packages needed for building the C++ crawler and running the PHP application. It also installs the PHP development dependencies from Composer so the local PHP tests can run later.
./scripts/build.sh --run-testsUse this after setup. It configures CMake, builds the crawler, and runs the C++ tests so you know the compiled part of the project is healthy before you start indexing anything.
./scripts/run_crawler.shUse this to create or refresh the SQLite catalog. This script simply forwards your arguments to the built crawler executable, but it gives you an obvious entry point and checks that the project has been built first.
./scripts/run_web_application.shUse this to start the PHP web interface. The script generates a temporary local XML configuration file for you, so you do not have to edit the tracked configuration file just to point the web app at your local SQLite database.
./scripts/test.shUse this any time you want one obvious command for local verification. It runs the C++ build and test workflow and then runs the PHP coding standards, PHP static analysis, and PHPUnit commands.
For a first run, use a small directory under /tmp so the results stay easy to
inspect:
mkdir -p /tmp/tusho-demo
touch /tmp/tusho-demo/example.txt
mkdir -p /tmp/tusho-demo/folder
composer install completesBuild completed successfully../build/tusho_crawler--database-path--log-file-pathhttp://127.0.0.1:8080./scripts/test.sh finishes without stoppingAll local tests completed successfully.