Deduplicating desktop backup for your files, powered by restic
  • TypeScript 93%
  • CSS 4.8%
  • JavaScript 2.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
balnaimi 1236c863ef
All checks were successful
test / test (push) Successful in 46s
build-and-release / appimage (push) Successful in 48s
chore(release): v1.5.1
2026-10-09 21:57:23 +03:00
.forgejo/workflows feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
build feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
scripts fix(lint): drop dead icon helper and ignore local scratch dirs 2026-09-27 21:44:21 +03:00
src fix: IPC listeners received their arguments one position off 2026-10-09 21:57:23 +03:00
tests fix: IPC listeners received their arguments one position off 2026-10-09 21:57:23 +03:00
vendor feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
.editorconfig chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
.gitignore feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
.npmrc feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
.prettierignore chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
.prettierrc chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
AGENTS.md feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
CHANGELOG.md chore(release): v1.5.1 2026-10-09 21:57:23 +03:00
electron-builder.yml feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
electron.vite.config.ts chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
eslint.config.mjs fix(lint): drop dead icon helper and ignore local scratch dirs 2026-09-27 21:44:21 +03:00
LICENSE chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
package-lock.json chore(release): v1.5.1 2026-10-09 21:57:23 +03:00
package.json chore(release): v1.5.1 2026-10-09 21:57:23 +03:00
README.md feat: restic-backed backup sets with file-type selection 2026-09-27 21:37:32 +03:00
tsconfig.json chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
tsconfig.node.json chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
tsconfig.web.json chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00
vitest.config.ts chore: scaffold hafiza from desktop-standard 2026-09-27 21:24:01 +03:00

حافظة / Hafiza

نسخ احتياطي لملفاتك مع ديدوبلكيشن، مبني على محرّك restic.

Deduplicating desktop backup for your files, powered by the bundled restic engine.

مبني على desktop-standard. Built on desktop-standard.


ما الذي يميّزه؟ / What makes it different

  • ديدوبلكيشن حقيقي — الملفات غير المتغيّرة لا تُخزَّن مرتين، لا داخل النسخة الواحدة ولا بين النسخ ولا بين المجموعات، لأن المحرّك يقسّم البيانات إلى chunks ويعتمد على البصمة.

  • اختيار دقيق للملفات — اختر أنواعًا كاملة (صور، فيديو، صوت، مستندات، أرشيفات، كود، أخرى) أو امتداداتك الخاصة، مع حدود حجم وتاريخ واستثناءات مجلدات.

  • معاينة قبل النسخ — عدد الملفات والحجم والتوزيع حسب النوع وأكثر الامتدادات، وكم ملفًا استُثني ولماذا.

  • أوفلاين بالكامل — محرّك restic مضمّن داخل التطبيق، والخطوط مضمّنة، ولا اتصال بالإنترنت إلا لفحص التحديث.

  • عربي/إنجليزي مع RTL/LTR، وثيم فاتح/داكن يتبع النظام.

  • Real deduplication — unchanged data is stored once, within a snapshot, across snapshots, and across backup sets.

  • Precise file selection — whole categories (images, videos, audio, documents, archives, code, other) or your own extension list, plus size, age and folder exclusions.

  • Preview before writing — file count, total size, per-category breakdown, the most common extensions, and how many files were skipped and why.

  • Fully offline — restic is bundled, fonts are embedded; only the update check uses the network, and it fails silently.

  • Arabic/English with RTL/LTR, and a light/dark theme that follows the system.

كيف يعمل؟ / How it works

Hafiza does not reimplement backup. It scans the folders you chose, applies your rules, writes the selected paths into a NUL-separated manifest, and runs restic backup --files-from-raw with that manifest. The whole engine stays in the Electron main process and the renderer only talks to it through a typed, validated IPC surface.

A path list is used instead of restic exclude globs on purpose: restic cannot re-include files inside an excluded directory, so "only these file types" is impossible to express with patterns. The manifest also guarantees that the snapshot contains exactly what the preview showed.

التثبيت والتشغيل / Install & run

npm install
npm run fetch:restic # ينزّل محرّك restic ويتحقّق من بصمته / download + verify the engine
npm run dev          # التطوير / development
npm test             # الاختبارات / tests
HAFIZA_IT=1 npm test # اختبار تكاملي بمحرّك restic الحقيقي / real-engine integration test
npm run typecheck    # فحص الأنواع / type checking
npm run lint         # فحص الكود / lint
npm run gen:icon     # توليد الأيقونات / generate icons
npm run dist         # بناء AppImage / build AppImage

محرّك restic لا يُرفع إلى git؛ يُنزَّل عند البناء من الإصدار المثبَّت في vendor/versions.json بعد التحقق من بصمة SHA-256.

The restic binary is not committed; it is downloaded at build time from the release pinned in vendor/versions.json after its SHA-256 checksum is verified.

الاستخدام / Usage

  1. اضبط مستودعًا: مجلد محلي أو SFTP أو خادم REST، مع كلمة سر التشفير.
  2. أنشئ «مجموعة نسخ»: اختر المجلدات، ثم «كل الملفات» أو أنواعًا محددة، واضبط الفلاتر المتقدمة.
  3. اضغط «معاينة الاختيار» للتأكد من العدد والحجم، ثم «انسخ الآن».
  4. من صفحة «النسخ المحفوظة» استعرض أي نسخة واستعِد ما تريد، ومن صفحة «الصحة» افحص المستودع وطبّق سياسة الاحتفاظ.

تنبيه: كلمة سر المستودع هي مفتاح بياناتك. إذا ضاعت، لا يمكن استرجاع النسخ — المحرّك يشفّر كل شيء على جهازك.

  1. Set up a repository: a local folder, SFTP, or a REST server, with its encryption password.
  2. Create a backup set: pick folders, choose "Everything" or specific file types, tune the filters.
  3. Press "Preview selection" to check the count and size, then "Back up now".
  4. Browse and restore from the Snapshots page; verify the repository and apply retention on the Health page.

Warning: the repository password is the key to your data. Without it the snapshots cannot be recovered — restic encrypts everything locally.

التحميل / Download

من صفحة Releases: نزّل أحدث ملف hafiza-<version>.AppImage، ثم:

chmod +x hafiza-<version>.AppImage
./hafiza-<version>.AppImage

الترخيص / License

هذا العمل مرخّص تحت CC BY-NC-SA 4.0 — استخدام غير تجاري مع مشاركة بالمثل.

محرّك restic المضمّن مرخّص بـ BSD-2-Clause (انظر vendor/versions.json).

This work is licensed under CC BY-NC-SA 4.0 — non-commercial, share-alike.

The bundled restic engine is licensed under BSD-2-Clause (see vendor/versions.json).