update packages

This commit is contained in:
2021-01-08 19:32:30 +01:00
parent ce8f24d28a
commit f5649dceab
467 changed files with 26642 additions and 22487 deletions

View File

@@ -1,6 +1,6 @@
;;; treemacs.el --- A tree style file viewer package -*- lexical-binding: t -*-
;; Copyright (C) 2020 Alexander Miller
;; Copyright (C) 2021 Alexander Miller
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
@@ -35,7 +35,7 @@
(require 'inline)
(require 'treemacs-macros))
(defconst treemacs--dirs-to-collpase.py
(defconst treemacs--dirs-to-collapse.py
(if (member "treemacs-dirs-to-collapse.py" (directory-files treemacs-dir))
(f-join treemacs-dir "treemacs-dirs-to-collapse.py")
(f-join treemacs-dir "src/scripts/treemacs-dirs-to-collapse.py")))
@@ -58,9 +58,9 @@ If it does reach that size it will be cut back to 30 entries.")
"Stores the results of previous git status calls for directories.
Its effective type is HashMap<FilePath, HashMap<FilePath, Char>>.
These cached results are used as a standin during immediate rendering when
`treemacs-git-mode' is set to be deferred, so as to minimize the effect of large
face changes, epsecially when a full project is refreshed.
These cached results are used as a stand-in during immediate rendering when
`treemacs-git-mode' is set to be deferred, so as to minimise the effect of large
face changes, especially when a full project is refreshed.
Since this table is a global value that can effectively grow indefinitely its
value is limited by `treemacs--git-cache-max-size'.")
@@ -155,10 +155,7 @@ really left to do is pick up the cons list and put it in a hash table.
GIT-FUTURE: Pfuture"
(or (when git-future
(let* ((git-output (pfuture-await-to-finish git-future))
;; Check fboundp in case an old version of pfuture is used.
;; TODO: Remove the check when pfuture 1.7 has been widely adopted.
(git-stderr (when (fboundp 'pfuture-stderr)
(pfuture-stderr git-future))))
(git-stderr (pfuture-stderr git-future)))
;; Check stderr separately from parsing, often git status displays
;; warnings which do not affect the final result.
(unless (s-blank? git-stderr)
@@ -262,7 +259,7 @@ BUFFER: Buffer"
"Update the FILE node's git state, wrapped in `treemacs-save-position'.
Internally calls `treemacs-do-update-single-file-git-state'.
FILE: Filepath"
FILE: FilePath"
(treemacs-save-position
(treemacs-do-update-single-file-git-state file)))
@@ -280,7 +277,7 @@ cache entry.
When OVERRIDE-STATUS is non-nil the FILE's cached git status will not be used.
FILE: Filepath
FILE: FilePath
EXCLUDE-PARENTS: Boolean
OVERRIDE-STATUS: Boolean"
(let* ((local-buffer (current-buffer))
@@ -336,13 +333,13 @@ OVERRIDE-STATUS: Boolean"
(treemacs-log-err "\"%s\"" (treemacs--remove-trailing-newline err-str))))))))))
(defun treemacs--collapsed-dirs-process (path project)
"Start a new process to determine dirs to collpase under PATH.
"Start a new process to determine directories to collapse under PATH.
Only starts the process if PROJECT is locally accessible (i.e. exists, and
is not remote.)
Output format is an elisp list of string lists that's read directly.
Every string list consists of the following elements:
1) the extra text that must be appended in the view
2) The original full and uncollapsed path
2) The original full and non-collapsed path
3) a series of intermediate steps which are the result of appending the
collapsed path elements onto the original, ending in
4) the full path to the
@@ -359,13 +356,13 @@ Every string list consists of the following elements:
(-let [default-directory path]
(pfuture-new treemacs-python-executable
"-O"
treemacs--dirs-to-collpase.py
treemacs--dirs-to-collapse.py
path
(number-to-string treemacs-collapse-dirs)
(if treemacs-show-hidden-files "t" "x")))))
(defun treemacs--parse-collapsed-dirs (future)
"Parse the output of collpsed dirs FUTURE.
"Parse the output of collapsed dirs FUTURE.
Splits the output on newlines, splits every line on // and swallows the first
newline."
(when future
@@ -400,8 +397,9 @@ All versions run asynchronously and are optimized for not doing more work than
is necessary, so their performance cost should, for the most part, be the
constant time needed to fork a subprocess."
:init-value nil
:global t
:lighter nil
:global t
:lighter nil
:group 'treemacs
(if treemacs-git-mode
(if (memq arg '(simple extended deferred))
(treemacs--setup-git-mode arg)