<commit_before>;;; danny.el --- Danny (download nanny) package. -*- lexical-binding: t; -*-

;;; Commentary:
;; Danny monitors downloads and offers quick actions.


;;; Code:

(require 'cl)
(require 'dash)
(require 'f)
(require 'filenotify)
(require 'ht)
(require 'ivy)

(defvar danny-monitor-dir-path "~/Downloads" "Directory path to monitor.")

(cl-defstruct
    danny-destination-root
  name
  dpath
  recursive)

(defvar danny-ignored-extensions (list "crdownload"
                                       "part")
  "List of ignored extensions (omit period).
These are typically temp files created during downloads.

For example \"crdownload\" \"part\".")

(defvar danny-destination-roots
  (list (make-danny-destination-root :name "Documents"
                                     :dpath "~/Documents")
        (make-danny-destination-root :name "Downloads"
                                     :dpath "~/Downloads"
                                     :recursive t)
        (make-danny-destination-root :name "Temp"
                                     :dpath "/tmp"))
  "Root destination directories.  For example:

  (list (make-danny-destination-root :name \"Documents\"
                                     :dpath \"~/Documents\")
        (make-danny-destination-root :name \"Stuff\"
                                     :dpath \"~/Stuff\"))")

(defvar danny--notify-descriptor nil "File notify descriptor.")

(defvar danny--history-hash (ht) "History hashtable.")<commit_msg>Adding more danny-ignored-extensions<commit_after>;;; danny.el --- Danny (download nanny) package. -*- lexical-binding: t; -*-

;;; Commentary:
;; Danny monitors downloads and offers quick actions.


;;; Code:

(require 'cl)
(require 'dash)
(require 'f)
(require 'filenotify)
(require 'ht)
(require 'ivy)

(defvar danny-monitor-dir-path "~/Downloads" "Directory path to monitor.")

(cl-defstruct
    danny-destination-root
  name
  dpath
  recursive)

(defvar danny-ignored-extensions (list "crdownload"
                                       "part"
                                       "m4a"
                                       "ytdl")
  "List of ignored extensions (omit period).
These are typically temp files created during downloads.

For example \"crdownload\" \"part\".")

(defvar danny-destination-roots
  (list (make-danny-destination-root :name "Documents"
                                     :dpath "~/Documents")
        (make-danny-destination-root :name "Downloads"
                                     :dpath "~/Downloads"
                                     :recursive t)
        (make-danny-destination-root :name "Temp"
                                     :dpath "/tmp"))
  "Root destination directories.  For example:

  (list (make-danny-destination-root :name \"Documents\"
                                     :dpath \"~/Documents\")
        (make-danny-destination-root :name \"Stuff\"
                                     :dpath \"~/Stuff\"))")

(defvar danny--notify-descriptor nil "File notify descriptor.")

(defvar danny--history-hash (ht) "History hashtable.")
{'fraction_non_alphanumeric': 0.1292207792207792, 'fraction_numerical': 0.0003246753246753247, 'mean_word_length': 1.8448753462603877, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 32, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2309700', 'n_tokens_mistral': 900, 'n_tokens_neox': 843, 'n_words': 225}