<commit_before>;;; module-php.el

(use-package php-mode
  :mode "\\.\\(php\\|inc\\)$"
  :init
  (add-hook! php-mode 'flycheck-mode)
  (setq php-template-compatibility nil
        php-extras-eldoc-functions-file (concat narf-temp-dir "php-extras-eldoc-functions"))

  :config
  (require 'php-extras)
  (define-company-backend! php-mode '(php-extras-company))

  (unless (file-exists-p (concat php-extras-eldoc-functions-file ".el"))
    (async-start `(lambda ()
                    ,(async-inject-variables "\\`\\(load-path\\|php-extras-eldoc-functions-file\\)$")
                    (require 'php-extras-gen-eldoc)
                    (php-extras-generate-eldoc-1 t))
                 (lambda (_)
                   (load (concat php-extras-eldoc-functions-file ".el"))
                   (message "PHP eldoc updated!"))))

  ;; TODO Tie into emr
  (require 'php-refactor-mode)
  (add-hook! php-mode '(turn-on-eldoc-mode emr-initialize php-refactor-mode)))

(use-package php-boris :defer t
  :init
  (define-repl! php-mode php-boris)
  :config
  (evil-set-initial-state 'php-boris-mode 'emacs)
  (setq php-boris-command "~/.dotfiles/scripts/run-boris"))

(use-package hack-mode :mode "\\.hh$")

(provide 'module-php)
;;; module-php.el ends here<commit_msg>php-mode: prevent company autoconfig<commit_after>;;; module-php.el

(use-package php-mode
  :mode "\\.\\(php\\|inc\\)$"
  :init
  (add-hook! php-mode 'flycheck-mode)
  (setq php-template-compatibility nil
        php-extras-eldoc-functions-file (concat narf-temp-dir "php-extras-eldoc-functions"))
  :config
  (require 'php-extras)
  (defun php-extras-company-setup ()) ;; company will set up itself
  (define-company-backend! php-mode '(php-extras-company))

  (unless (file-exists-p (concat php-extras-eldoc-functions-file ".el"))
    (async-start `(lambda ()
                    ,(async-inject-variables "\\`\\(load-path\\|php-extras-eldoc-functions-file\\)$")
                    (require 'php-extras-gen-eldoc)
                    (php-extras-generate-eldoc-1 t))
                 (lambda (_)
                   (load (concat php-extras-eldoc-functions-file ".el"))
                   (message "PHP eldoc updated!"))))

  ;; TODO Tie into emr
  (require 'php-refactor-mode)
  (add-hook! php-mode '(turn-on-eldoc-mode emr-initialize php-refactor-mode)))

(use-package php-boris :defer t
  :init
  (define-repl! php-mode php-boris)
  :config
  (evil-set-initial-state 'php-boris-mode 'emacs)
  (setq php-boris-command "~/.dotfiles/scripts/run-boris"))

(use-package hack-mode :mode "\\.hh$")

(provide 'module-php)
;;; module-php.el ends here
{'fraction_non_alphanumeric': 0.17640276710222905, 'fraction_numerical': 0.0007686395080707148, 'mean_word_length': 2.6052631578947367, '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': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '620776', 'n_tokens_mistral': 971, 'n_tokens_neox': 911, 'n_words': 169}