Git Product home page Git Product logo

Comments (19)

hyiltiz avatar hyiltiz commented on May 21, 2024

I think that happens when the reading .csv file happens. Apparently R is naming the columns as V1, V2, V3, V4 by default in my computer, but not in all cases. I like being explicit about it, and will update to resolve this issue today. Also, I will try to have a proper note about installing R and its dependent packages.

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

I have updated the file, and hopefully d7c0724 will resolve the issue. Please go ahead and see master is now good to go.

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

Still no output unfortunately, but now it's outputting the the warning:
cannot open file 'profile.csv': No such file or directory>

-this is in osx by the way

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

Can you please remove --quiet --vanilla from the call to R in the bash script, and run the bash script with command below?

sh -x ./vim-plugins-profile.sh

And please post your outputs of this command so that I can tell what is happening. I am testing in OSX and Debian Testing as well, so we should not be experiencing a cross-platform issue.

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

Sure, here is the output:

~/m/vim-plugins-profile ❯❯❯ sh -x ./vim-plugins-profile.sh                                                                                                                  master ✱
sh -x ./vim-plugins-profile.sh @ 04:40:35 pm...
+ set -eu
+ echo 'Generating vim startup profile...'
Generating vim startup profile...
+ logfile=vim.log
+ '[' -f vim.log ']'
+ rm vim.log
override rw-r--r--  root/staff for vim.log? yes
+ vim --startuptime vim.log -c q
+ whichPlugin=plugged
+ echo 'Parsing vim startup profile...'
Parsing vim startup profile...
+ grep plugged vim.log
+ awk -F: '{print $1}' tmp.log
+ awk -F: '{print $2}' tmp.log
+ awk -F: '{print $2}' tmp.log
+ sed 's/.*plugged\///g'
+ sed 's/\/.*//g'
+ paste tmp1.log tmp2.log
+ sed 's/\s\+/,/g'
+ rm tmp.log tmp1.log tmp2.log
+ echo 'Crunching data and generating profile plot ...'
Crunching data and generating profile plot ...
+ echo ' '

+ type R
+ R --file=vim-plugins-profile-plot.R

R version 3.2.2 (2015-08-14) -- "Fire Safety"
Copyright (C) 2015 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin15.0.0 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> if("ggplot2" %in% rownames(installed.packages()) == FALSE) {
+
+   isOk <- FALSE
+   # we need to install the ggplot2 package
+   while(!isOk){
+     message("Trying in install the required R:ggplot2 package. Confirm? (y/n)")
+     ANSWER <- readLines(con="stdin", 1)
+     if (tolower(substr(ANSWER, 1,1)) == "y" ) {
+       isOk = TRUE
+       message("Confirmed to install.")
+       message(" ")
+       message("==========================================\n")
+       message("Installing required R dependency package...\n")
+
+       # install the required package if not present from the default package repository
+       install.packages("ggplot2", repos="http://cran.rstudio.com/")
+       message("Installation  finished!\n")
+       message("==========================================\n")
+     }
+     else {
+       isOk = FALSE
+       message("You did not say yes, so aborting.")
+       return(-1)
+     }
+   }
+ }
>
>
> out <- tryCatch(
+                 {
+                   require(ggplot2)
+                   dat <- read.csv("profile.csv", header = FALSE, col.names = c("TraceTime", "SourceTime", "ExecTime", "PluginName"))
+                   png("profile.png", width = 1366, height = 768)
+                   qplot(PluginName, ExecTime, data = dat, stat = "summary", fun.y = "sum", geom = "bar") + coord_flip() + xlab("Installed Plugins") + ylab("Startup Time (ms)")
+                   dev.off()
+
+                   dat.n <- aggregate(ExecTime ~ PluginName, data = dat, "sum")
+                   dat.n <- dat.n[order(dat.n$ExecTime, decreasing = TRUE),]
+                   dat.n <- dat.n[,2:1]
+                   write.table(dat.n, "results.csv", sep = "\t", row.names = FALSE)
+
+                 },
+                 error=function(cond) {
+                   message("Package R caused an error!")
+                   message("Here's the original error message:")
+                   message(cond)
+                   # Choose a return value in case of error
+                   return(NA)
+                 },
+                 warning=function(cond) {
+                   message("Package R caused a warning:")
+                   message("Here's the original warning message:")
+                   message(cond)
+                   # Choose a return value in case of warning
+                   return(NULL)
+                 },
+                 finally={
+                   # NOTE:
+                   # Here goes everything that should be executed at the end,
+                   # regardless of success or error.
+
+                   # Do nothing
+                 }
+                 )
Loading required package: ggplot2
Package R caused an error!
Here's the original error message:
no rows to aggregate>
+ rm profile.csv
+ echo ' '

+ echo 'Your plugins startup profile graph is saved '
Your plugins startup profile graph is saved
+ echo 'as `profile.png` under current directory.'
as `profile.png` under current directory.
+ echo ' '

+ echo ==========================================
==========================================
+ echo 'Top 10 Plugins That Slows Down Vim Startup'
Top 10 Plugins That Slows Down Vim Startup
+ echo ==========================================
==========================================
+ cat -n results.csv
+ head -n 10
cat: results.csv: No such file or directory
+ echo ==========================================
==========================================
+ echo 'Done!'
Done!
+ echo ' '

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

R is saying no rows to aggregate, which might indicate that it has problem reading your vim.log file, or the file might not have been created in the first place. Could you please post the contents of your log file? It should be stored, or you could simply generate with: vim --startuptime vim.log -c q
`

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

No problem:



times in msec
 clock   self+sourced   self:  sourced script
 clock   elapsed:              other lines

000.007  000.007: --- VIM STARTING ---
000.096  000.089: Allocated generic buffers
001.415  001.319: locale set
001.428  000.013: clipboard setup
001.447  000.019: window checked
002.348  000.901: inits 1
002.367  000.019: parsing arguments
002.369  000.002: expanding arguments
007.925  005.556: shell init
008.621  000.696: Termcap init
008.657  000.036: inits 2
008.880  000.223: init highlight
013.762  003.510  003.510: sourcing /Users/deepanchor/.vim/autoload/plug.vim
026.507  000.065  000.065: sourcing /usr/local/share/vim/vim74/ftoff.vim
032.632  001.297  001.297: sourcing /Users/deepanchor/.vim/plugged/vim-ruby/ftdetect/ruby.vim
034.393  000.065  000.065: sourcing /Users/deepanchor/.vim/plugged/tern_for_vim/ftdetect/tern.vim
036.161  000.118  000.118: sourcing /Users/deepanchor/.vim/plugged/vim-javascript/ftdetect/javascript.vim
039.231  000.081  000.081: sourcing /Users/deepanchor/dotfiles/vim/plugged/vim-jsx/after/jsx-config.vim
039.320  002.015  001.934: sourcing /Users/deepanchor/.vim/plugged/vim-jsx/after/ftdetect/javascript.vim
041.150  000.245  000.245: sourcing /Users/deepanchor/.vim/plugged/vim-go/ftdetect/gofiletype.vim
071.674  000.146  000.146: sourcing /Users/deepanchor/.vim/plugged/ultisnips/ftdetect/snippets.vim
072.091  000.164  000.164: sourcing /Users/deepanchor/.vim/plugged/ultisnips/ftdetect/UltiSnips.vim
072.769  000.171  000.171: sourcing /Users/deepanchor/.vim/plugged/vim-markdown/ftdetect/markdown.vim
073.218  027.143  026.662: sourcing /usr/local/share/vim/vim74/filetype.vim
073.954  000.100  000.100: sourcing /usr/local/share/vim/vim74/ftplugin.vim
074.615  000.068  000.068: sourcing /usr/local/share/vim/vim74/indent.vim
076.400  000.266  000.266: sourcing /usr/local/share/vim/vim74/syntax/syncolor.vim
076.596  001.053  000.787: sourcing /usr/local/share/vim/vim74/syntax/synload.vim
076.642  001.724  000.671: sourcing /usr/local/share/vim/vim74/syntax/syntax.vim
077.377  000.228  000.228: sourcing /usr/local/share/vim/vim74/syntax/syncolor.vim
078.488  000.228  000.228: sourcing /usr/local/share/vim/vim74/syntax/syncolor.vim
079.219  000.229  000.229: sourcing /usr/local/share/vim/vim74/syntax/syncolor.vim
082.561  004.865  004.408: sourcing /Users/deepanchor/.vim/colors/enigma.vim
116.514  000.714  000.714: sourcing /Users/deepanchor/.vim/plugged/vim-repeat/autoload/repeat.vim
116.824  107.147  063.990: sourcing $HOME/.vimrc
116.832  000.805: sourcing vimrc file(s)
119.541  002.180  002.180: sourcing /Users/deepanchor/.vim/plugged/bufexplorer/plugin/bufexplorer.vim
120.097  000.129  000.129: sourcing /Users/deepanchor/.vim/plugged/BufOnly.vim/plugin/BufOnly.vim
122.822  000.971  000.971: sourcing /Users/deepanchor/.vim/plugged/delimitmate/autoload/delimitMate.vim
126.647  006.163  005.192: sourcing /Users/deepanchor/.vim/plugged/delimitmate/plugin/delimitMate.vim
128.193  001.158  001.158: sourcing /Users/deepanchor/.fzf/plugin/fzf.vim
129.557  001.010  001.010: sourcing /Users/deepanchor/.vim/plugged/fzf.vim/plugin/fzf.vim
130.029  000.091  000.091: sourcing /Users/deepanchor/.vim/plugged/gundo.vim/plugin/gundo.vim
132.321  000.456  000.456: sourcing /Users/deepanchor/.vim/plugged/nerdtree/autoload/nerdtree.vim
134.908  000.980  000.980: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/path.vim
135.693  000.385  000.385: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/menu_controller.vim
136.177  000.155  000.155: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/menu_item.vim
137.001  000.375  000.375: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/key_map.vim
137.897  000.524  000.524: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/bookmark.vim
138.878  000.660  000.660: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/tree_file_node.vim
140.612  000.903  000.903: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/tree_dir_node.vim
141.862  000.569  000.569: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/opener.vim
143.546  000.621  000.621: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/creator.vim
144.045  000.121  000.121: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/flag_set.vim
144.557  000.184  000.184: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/nerdtree.vim
145.599  000.715  000.715: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/ui.vim
145.881  000.060  000.060: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/event.vim
146.336  000.152  000.152: sourcing /Users/deepanchor/.vim/plugged/nerdtree/lib/nerdtree/notifier.vim
147.958  001.184  001.184: sourcing /Users/deepanchor/.vim/plugged/nerdtree/autoload/nerdtree/ui_glue.vim
173.300  002.401  002.401: sourcing /Users/deepanchor/.vim/plugged/nerdtree-git-plugin/nerdtree_plugin/git_status.vim
175.145  001.378  001.378: sourcing /Users/deepanchor/.vim/plugged/vim-nerdtree-tabs/nerdtree_plugin/vim-nerdtree-tabs.vim
175.977  000.196  000.196: sourcing /Users/deepanchor/.vim/plugged/nerdtree/nerdtree_plugin/exec_menuitem.vim
177.014  000.806  000.806: sourcing /Users/deepanchor/.vim/plugged/nerdtree/nerdtree_plugin/fs_menu.vim
177.883  047.458  034.633: sourcing /Users/deepanchor/.vim/plugged/nerdtree/plugin/NERD_tree.vim
180.343  002.026  002.026: sourcing /Users/deepanchor/.vim/plugged/SearchParty/plugin/SearchParty.vim
183.454  002.688  002.688: sourcing /Users/deepanchor/.vim/plugged/supertab/plugin/supertab.vim
184.546  000.708  000.708: sourcing /Users/deepanchor/.vim/plugged/tabular/plugin/Tabular.vim
186.649  001.683  001.683: sourcing /Users/deepanchor/.vim/plugged/tagbar/plugin/tagbar.vim
187.795  000.192  000.192: sourcing /Users/deepanchor/.vim/plugged/ultisnips/autoload/UltiSnips/map_keys.vim
187.953  000.899  000.707: sourcing /Users/deepanchor/.vim/plugged/ultisnips/plugin/UltiSnips.vim
188.418  000.087  000.087: sourcing /Users/deepanchor/.vim/plugged/vim-snippets/plugin/vimsnippets.vim
188.997  000.234  000.234: sourcing /Users/deepanchor/.vim/plugged/vim-bbye/plugin/bbye.vim
189.835  000.492  000.492: sourcing /Users/deepanchor/.vim/plugged/vim-commentary/plugin/commentary.vim
199.710  009.376  009.376: sourcing /Users/deepanchor/.vim/plugged/vim-easymotion/plugin/EasyMotion.vim
201.217  001.067  001.067: sourcing /Users/deepanchor/.vim/plugged/vim-eunuch/plugin/eunuch.vim
202.944  000.863  000.863: sourcing /Users/deepanchor/.vim/plugged/vim-expand-region/autoload/expand_region.vim
203.191  001.597  000.734: sourcing /Users/deepanchor/.vim/plugged/vim-expand-region/plugin/expand_region.vim
211.408  007.831  007.831: sourcing /Users/deepanchor/.vim/plugged/vim-fugitive/plugin/fugitive.vim
213.304  000.387  000.387: sourcing /Users/deepanchor/.vim/plugged/vim-gitgutter/autoload/gitgutter/highlight.vim
214.672  002.843  002.456: sourcing /Users/deepanchor/.vim/plugged/vim-gitgutter/plugin/gitgutter.vim
216.113  000.555  000.555: sourcing /Users/deepanchor/.vim/plugged/vim-indent-guides/autoload/indent_guides.vim
216.994  001.936  001.381: sourcing /Users/deepanchor/.vim/plugged/vim-indent-guides/plugin/indent_guides.vim
218.001  000.569  000.569: sourcing /Users/deepanchor/.vim/plugged/vim-multiple-cursors/plugin/multiple_cursors.vim
218.868  000.033  000.033: sourcing /usr/local/share/vim/vim74/filetype.vim
219.285  000.029  000.029: sourcing /usr/local/share/vim/vim74/ftplugin.vim
219.686  000.027  000.027: sourcing /usr/local/share/vim/vim74/indent.vim
223.629  001.275  001.275: sourcing /usr/local/share/vim/vim74/macros/matchit.vim
223.745  005.358  003.994: sourcing /Users/deepanchor/.vim/plugged/vim-sensible/plugin/sensible.vim
225.331  001.206  001.206: sourcing /Users/deepanchor/.vim/plugged/vim-surround/plugin/surround.vim
225.991  000.255  000.255: sourcing /Users/deepanchor/.vim/plugged/vim-startify/plugin/startify.vim
231.096  004.659  004.659: sourcing /Users/deepanchor/.vim/plugged/vim-unimpaired/plugin/unimpaired.vim
232.853  000.789  000.789: sourcing /Users/deepanchor/.vim/plugged/vim-yankstack/autoload/yankstack.vim
234.184  002.644  001.855: sourcing /Users/deepanchor/.vim/plugged/vim-yankstack/plugin/yankstack.vim
235.522  000.874  000.874: sourcing /Users/deepanchor/.vim/plugged/youcompleteme/plugin/youcompleteme.vim
236.026  000.090  000.090: sourcing /Users/deepanchor/.vim/plugged/goyo.vim/plugin/goyo.vim
236.518  000.157  000.157: sourcing /Users/deepanchor/.vim/plugged/limelight.vim/plugin/limelight.vim
237.460  000.072  000.072: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/autoloclist.vim
237.712  000.060  000.060: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/balloons.vim
237.954  000.058  000.058: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/checker.vim
238.195  000.061  000.061: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/cursor.vim
238.453  000.061  000.061: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/highlighting.vim
238.698  000.071  000.071: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/loclist.vim
238.948  000.062  000.062: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/modemap.vim
239.205  000.066  000.066: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/notifiers.vim
239.461  000.066  000.066: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/registry.vim
239.724  000.067  000.067: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/signs.vim
241.661  000.941  000.941: sourcing /Users/deepanchor/.vim/plugged/syntastic/autoload/syntastic/util.vim
303.332  000.097  000.097: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/autoloclist.vim
303.485  000.104  000.104: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/balloons.vim
304.083  000.557  000.557: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/checker.vim
304.312  000.159  000.159: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/cursor.vim
304.491  000.127  000.127: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/highlighting.vim
305.317  000.784  000.784: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/loclist.vim
305.530  000.145  000.145: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/modemap.vim
305.685  000.111  000.111: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/notifiers.vim
306.496  000.770  000.770: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/registry.vim
306.950  000.389  000.389: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic/signs.vim
308.540  068.606  064.422: sourcing /Users/deepanchor/.vim/plugged/syntastic/plugin/syntastic.vim
310.211  000.489  000.489: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline.vim
311.419  000.474  000.474: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/init.vim
313.100  000.206  000.206: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/parts.vim
313.988  005.063  003.894: sourcing /Users/deepanchor/.vim/plugged/vim-airline/plugin/airline.vim
314.901  000.498  000.498: sourcing /Users/deepanchor/.vim/plugged/vim-autoformat/plugin/autoformat.vim
315.749  000.623  000.623: sourcing /Users/deepanchor/.vim/plugged/vim-autoformat/plugin/defaults.vim
316.734  000.148  000.148: sourcing /usr/local/share/vim/vim74/plugin/getscriptPlugin.vim
317.419  000.483  000.483: sourcing /usr/local/share/vim/vim74/plugin/gzip.vim
318.135  000.472  000.472: sourcing /usr/local/share/vim/vim74/plugin/logiPat.vim
318.624  000.371  000.371: sourcing /usr/local/share/vim/vim74/plugin/matchparen.vim
319.874  001.140  001.140: sourcing /usr/local/share/vim/vim74/plugin/netrwPlugin.vim
320.116  000.074  000.074: sourcing /usr/local/share/vim/vim74/plugin/rrhelper.vim
320.328  000.083  000.083: sourcing /usr/local/share/vim/vim74/plugin/spellfile.vim
320.830  000.376  000.376: sourcing /usr/local/share/vim/vim74/plugin/tarPlugin.vim
321.209  000.241  000.241: sourcing /usr/local/share/vim/vim74/plugin/tohtml.vim
321.597  000.242  000.242: sourcing /usr/local/share/vim/vim74/plugin/vimballPlugin.vim
322.132  000.397  000.397: sourcing /usr/local/share/vim/vim74/plugin/zipPlugin.vim
323.086  000.116  000.116: sourcing /Users/deepanchor/.vim/plugged/SearchParty/autoload/searchparty/mash.vim
323.163  000.609  000.493: sourcing /Users/deepanchor/.vim/plugged/SearchParty/after/plugin/searchparty_force_mash_maps.vim
324.838  000.732  000.732: sourcing /Users/deepanchor/.vim/plugged/tabular/autoload/tabular.vim
327.557  004.023  003.291: sourcing /Users/deepanchor/.vim/plugged/tabular/after/plugin/TabularMaps.vim
328.299  000.307  000.307: sourcing /Users/deepanchor/.vim/plugged/ultisnips/after/plugin/UltiSnips_after.vim
328.364  019.664: loading plugins
328.376  000.012: inits 3
329.460  001.084: reading viminfo
329.498  000.038: setting raw mode
329.519  000.021: start termcap
329.577  000.058: clearing screen
600.323  000.761  000.761: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions.vim
601.247  000.160  000.160: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/quickfix.vim
602.129  000.142  000.142: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/netrw.vim
603.124  000.225  000.225: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/hunks.vim
604.054  000.185  000.185: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tagbar.vim
605.124  000.318  000.318: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/branch.vim
606.119  000.136  000.136: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/syntastic.vim
607.186  000.317  000.317: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/whitespace.vim
608.265  000.167  000.167: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/wordcount.vim
610.056  001.028  001.028: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tabline.vim
611.304  000.226  000.226: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tabline/autoshow.vim
612.612  000.231  000.231: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tabline/tabs.vim
614.050  000.609  000.609: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tabline/buffers.vim
617.710  000.211  000.211: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/section.vim
619.803  000.750  000.750: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/highlighter.vim
623.582  000.198  000.198: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/themes.vim
624.942  002.303  002.105: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/themes/jellybeans.vim
632.232  000.264  000.264: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/util.vim
634.267  000.299  000.299: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/builder.vim
636.367  000.261  000.261: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/default.vim
656.726  318.556: opening buffers
664.912  000.867  000.867: sourcing /Users/deepanchor/.vim/plugged/vim-gitgutter/autoload/gitgutter.vim
666.573  000.891  000.891: sourcing /Users/deepanchor/.vim/plugged/vim-gitgutter/autoload/gitgutter/utility.vim
667.741  000.302  000.302: sourcing /Users/deepanchor/.vim/plugged/vim-gitgutter/autoload/gitgutter/hunk.vim
669.303  000.795  000.795: sourcing /Users/deepanchor/.vim/plugged/syntastic/autoload/syntastic/log.vim
670.248  010.667: BufEnter autocommands
670.257  000.009: editing files in windows
677.461  000.193  000.193: sourcing /Users/deepanchor/.vim/plugged/vim-airline/autoload/airline/extensions/tabline/buflist.vim

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

Thank you so much! There is nothing wrong in your log file, and I was able to produce the figure, in the end. It turned out that there was a bug in the R code. Now I believe it is resolved. Please check out.

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

Hmm, still no luck on my end:

~/m/vim-plugins-profile ❯❯❯ sh -x ./vim-plugins-profile.sh                                                                                                                  master ✱
sh -x ./vim-plugins-profile.sh @ 06:06:30 pm...
+ set -eu
+ echo 'Generating vim startup profile...'
Generating vim startup profile...
+ logfile=vim.log
+ '[' -f vim.log ']'
+ vim --startuptime vim.log -c q
+ echo 'Assuming your vimfiles folder as `~/.vim/`'
Assuming your vimfiles folder as `~/.vim/`
+ vimfilesDir=/Users/deepanchor/.vim/
+ plugDir=
+ '[' -d /Users/deepanchor/.vim/plugged ']'
+ echo 'vim-plug has been detected.'
vim-plug has been detected.
+ plugDir=plugged
+ echo 'Parsing vim startup profile...'
Parsing vim startup profile...
+ grep plugged vim.log
+ awk -F: '{print $1}' tmp.log
+ awk -F: '{print $2}' tmp.log
+ awk -F: '{print $2}' tmp.log
+ sed 's/.*plugged\///g'
+ sed 's/\/.*//g'
+ paste tmp1.log tmp2.log
+ sed 's/\s\+/,/g'
+ rm tmp.log tmp1.log tmp2.log vim.log
+ echo 'Crunching data and generating profile plot ...'
Crunching data and generating profile plot ...
+ echo ' '

+ type R
+ R --slave --file=vim-plugins-profile-plot.R
Loading required package: ggplot2
Package R caused a warning:
Here's the original warning message:
Removed 123 rows containing missing values (stat_summary).+ rm profile.csv
+ echo ' '

+ echo 'Your plugins startup profile graph is saved '
Your plugins startup profile graph is saved
+ echo 'as `result.png` under current directory.'
as `result.png` under current directory.
+ echo ' '

+ echo ==========================================
==========================================
+ echo 'Top 10 Plugins That Slows Down Vim Startup'
Top 10 Plugins That Slows Down Vim Startup
+ echo ==========================================
==========================================
+ cat -n results.csv
+ head -n 10
cat: results.csv: No such file or directory
+ echo ==========================================
==========================================
+ echo 'Done!'
Done!
+ echo ' '

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

Please try git clean -Xf then run again? Also, found a typo in the filename. Updated. Try again?

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

It's still generating an empty png file with the same warning as above!

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

I am sorry, and it must be frustrating. Please make sure you use 1755c67. Also, you are using as a regular user (not as root), right?

I can get the result from your log above here.

result

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

No don't be sorry, it's not frustrating at all. I just want to see my pretty vim graph 😃

I'm using the latest commit in a clean directory and running the script as a regular user.
Do you think it could be related to this issue?

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

I believe that is separate issue, since I am not able to replicate your problem, I am not sure what is going on. I am going to do a clean clone again, and see if I can replicate your problem with the latest code and your log.

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

I redid the test but could not replicate your result in any way. Here is my software version (installed via brew):

R version 3.2.2 (2015-08-14) -- "Fire Safety"
Copyright (C) 2015 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin14.5.0 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-apple-darwin14.5.0 (64-bit)
Running under: OS X 10.11 (El Capitan)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base
> pack
package_version        packageEvent           packageSlot            packageStatus
package.skeleton       packageHasNamespace    packageSlot<-          packageVersion
packageDescription     packageName            packageStartupMessage  packBits
> packageVersion("ggplot2")
[1] ‘1.0.1>

from vim-plugins-profile.

DeepAnchor avatar DeepAnchor commented on May 21, 2024

ok, it turns out osx sed and gnu sed interpret tab characters differently, so the log data was not being correctly marshalled. I've sent you PR #4 which fixes that.

I've been bitten by this bug before, but I totally forgot about it.
cheers and thanks for the help! 🍻

from vim-plugins-profile.

davidosomething avatar davidosomething commented on May 21, 2024

also no result.csv and empty png here
this was from a clean clone of master just now, a clean install of homebrew/science R and letting the script install its own deps

The downloaded source packages are in
    ‘/private/var/folders/66/j6k_b0rn7_3fqmnd9wgx2rj40000gn/T/RtmpgH3AX2/downloaded_packages’
Installation  finished!

==========================================

Loading required package: ggplot2
Package R caused a warning:
Here's the original warning message:
Removed 132 rows containing missing values (stat_summary).
Your plugins startup profile graph is saved
as `result.png` under current directory.

==========================================
Top 10 Plugins That Slows Down Vim Startup
==========================================
cat: result.csv: No such file or directory
==========================================
Done!

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

I installed gnu utils and sum linked them as system default. Now I know that is where the problems emerge. Let's be compatible.

from vim-plugins-profile.

hyiltiz avatar hyiltiz commented on May 21, 2024

Merging your pull request. 92d830e should resolve the issue. Feel free to re-open if it still persists.

from vim-plugins-profile.

Related Issues (9)

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.