Giter Site home page Giter Site logo

dotfiles's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

dotfiles's Issues

ctags

Learn how they work. Update configuration if need be. ZSH? Vim?

Speed up ZSH prompt display time

Currently prompt rendering takes a second or so.

Several silly things going on, mostly dominated by version control cleverness.

  • Calling update_vcs_vars three times per prompt rendered.
    • Should remove this from preexec_functions and chpwd_functions
  • in_git_repo/in_hg_repo are currently functions calling hg/git respectively.
    • These are being used as conditionals in a bunch of places.
    • Should factor that out so that they're called once per prompt render, and the result cached and read from a variable from then on.
% zprof
num  calls                time                       self            name
-----------------------------------------------------------------------------------
 1)    5         967.41   193.48   81.38%    967.41   193.48   81.38%  in_hg_repo
 2)    5          89.57    17.91    7.53%     89.57    17.91    7.53%  in_git_repo
 3)    1         113.05   113.05    9.51%     61.06    61.06    5.14%  compinit
 4)    2          52.00    26.00    4.37%     52.00    26.00    4.37%  compaudit
 5)    6          11.96     1.99    1.01%     10.82     1.80    0.91%  source_if_readable
 6)    2           4.40     2.20    0.37%      4.40     2.20    0.37%  promptinit
 7)    5        1058.57   211.71   89.05%      1.23     0.25    0.10%  zsh_update_vcs_vars
 8)    6           1.14     0.19    0.10%      1.14     0.19    0.10%  compdef
 9)    1           0.78     0.78    0.07%      0.78     0.78    0.07%  bashcompinit
10)    5           0.37     0.07    0.03%      0.37     0.07    0.03%  zsh_clear_vcs_vars

-----------------------------------------------------------------------------------

 7)    5        1058.57   211.71   89.05%      1.23     0.25    0.10%  zsh_update_vcs_vars
       5/5         0.37     0.07    0.03%      0.37     0.07             zsh_clear_vcs_vars [10]
       5/5        89.57    17.91    7.53%     89.57    17.91             in_git_repo [2]
       5/5       967.41   193.48   81.38%    967.41   193.48             in_hg_repo [1]

-----------------------------------------------------------------------------------

       5/5       967.41   193.48   81.38%    967.41   193.48             zsh_update_vcs_vars [7]
 1)    5         967.41   193.48   81.38%    967.41   193.48   81.38%  in_hg_repo

-----------------------------------------------------------------------------------

 3)    1         113.05   113.05    9.51%     61.06    61.06    5.14%  compinit
       1/2        52.00    52.00    4.37%      1.36     1.36             compaudit [4]

-----------------------------------------------------------------------------------

       5/5        89.57    17.91    7.53%     89.57    17.91             zsh_update_vcs_vars [7]
 2)    5          89.57    17.91    7.53%     89.57    17.91    7.53%  in_git_repo

-----------------------------------------------------------------------------------

       1/2        52.00    52.00    4.37%      1.36     1.36             compinit [3]
       1/2        50.64    50.64    4.26%     50.64    50.64             compaudit [4]
 4)    2          52.00    26.00    4.37%     52.00    26.00    4.37%  compaudit
       1/2        50.64    50.64    4.26%     50.64    50.64             compaudit [4]

-----------------------------------------------------------------------------------

       1/6         2.23     2.23    0.19%      1.34     1.34             source_if_readable [5]
 5)    6          11.96     1.99    1.01%     10.82     1.80    0.91%  source_if_readable
       6/6         1.14     0.19    0.10%      1.14     0.19             compdef [8]
       1/6         2.23     2.23    0.19%      1.34     1.34             source_if_readable [5]

-----------------------------------------------------------------------------------

       1/2         3.62     3.62    0.30%      3.62     3.62             promptinit [6]
 6)    2           4.40     2.20    0.37%      4.40     2.20    0.37%  promptinit
       1/2         3.62     3.62    0.30%      3.62     3.62             promptinit [6]

-----------------------------------------------------------------------------------

       6/6         1.14     0.19    0.10%      1.14     0.19             source_if_readable [5]
 8)    6           1.14     0.19    0.10%      1.14     0.19    0.10%  compdef

-----------------------------------------------------------------------------------

 9)    1           0.78     0.78    0.07%      0.78     0.78    0.07%  bashcompinit

-----------------------------------------------------------------------------------

       5/5         0.37     0.07    0.03%      0.37     0.07             zsh_update_vcs_vars [7]
10)    5           0.37     0.07    0.03%      0.37     0.07    0.03%  zsh_clear_vcs_vars

Shell analysis

Ideally, all top 10 commands should be... 3 chars or less? 2? 1 is a stretch.

Obvious candidate:

  • cd
  • ssh
  • git
  • grep.. ? (at the start of a line though. gr?)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.