إعادة الفهرسة
Sometimes the ord database must be reindexed, which means deleting the database and restarting the indexing process with either ord index update or ord server. Reasons to reindex are:
- صدور إصدار جديد رئيسي لـ ord والذي يغير مخطط قاعدة البيانات
- تلف قاعدة البيانات بشكل ما بطريقة ما
قاعدة البيانات التي يستخدمها ord تسمى redb، لذا نعطي للفهرس اسم الملف الافتراضي index.redb. عادةً ما نخزن هذا الملف في مواقع مختلفة اعتمادًا على نظام التشغيل الخاص بك.
| Platform | Value | مثال |
|---|---|---|
| Linux | $XDG_DATA_HOME/ord or $HOME/.local/share/ord | /home/alice/.local/share/ord |
| macOS | $HOME/Library/Application Support/ord | /Users/Alice/Library/Application Support/ord |
| Windows | {FOLDERID_RoamingAppData}\ord | C:\Users\Alice\AppData\Roaming\ord |
لحذف قاعدة البيانات وإعادة فهرستها على نظام MacOS، يمكنك تشغيل الأوامر التالية في الطرفية (الترمينال):
rm ~/Library/Application Support/ord/index.redb
ord index update
You can of course also set the location of the data directory yourself with ord --datadir <DIR> index update or give it a specific filename and path with ord --index <FILENAME> index update.