-
-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't open file (win gvim) #48
Comments
Are you using gvim on cygwin? or %TEMP% is pointed on NFS volume? |
I am using gvim. Here's my gvim --version |
Where is your curl.exe? :echo findfile("curl.exe", substitute($PATH, ';', ',', 'g').";") |
it's in the same folder with my git.exe
shows
|
You seens to use curl that is bundled in msysgit. |
I tried the curl.exe from http://curl.haxx.se/ and results the same. Thx for your quick reply. |
Hmm, where did you put :echo findfile("curl.exe", substitute($PATH, ';', ',', 'g').";") And it seems that you don't use latest gist-vim.
What lines around can you see? |
I put the downloaded curl.exe into c:\windows\system32\ :echo findfile("curl.exe", substitute($PATH, ';', ',', 'g').";")
and the above shows:
|
Hmm, do you set |
No, I don't think I set "shell" variable. Could you provide more information about it? I did set the whole git\bin into my %PATH% because it told me it needs git command, is this relevant? I can't find the tmp file gvim mentioned ex: VIoB1.tmp(I did a full harddrive find) Could it be something about TMP or gvim itself? |
Please try 2 cases. _how tempname() works._ start gvim.exe as usual.
check the file is exists. _git/bin make this problem or not_ start cmd.exe
then, type |
case 1:
And no, the file does not exist. case 2:
And no, the file does not exist. |
What value of |
I tried to set TMP and tempname() now is
Then I add git into PATH and try to Gist It still goes:
And still , this tmp file does not exist. |
hmm, how about upgrade of vim? |
If the |
Tried the newest download package of gvim from vim.com, still the same. Tried to point TMP to C:, still the same. Guess I'll give windows up, go back to mac and linux... Is this only me or all gvim on windows got this issue? Should I close this issue if there's no one else but me? |
OK. Sorry for long time & Thanks. |
nope, thx for ur help and great plugin :) |
I'm having a similar problem on Windows 7: Error detected while processing C:\bin\files\edit\Vim\vim73\ftplugin\perl.vim: I bet this is one of those wacky Win 7 directory protection problems. The temp file isn't there because it's a temp file; vim is trying to CREATE it, not read it. I'm trying to run gvim from cygwin, so the user account whose privs are being checked may be the application's instead of my own. Win 7 permissions flat-out don't work. First, there's a bug with "read-only". Most directories on a Win 7 system (including this tmp directory) will get a "read-only" bit set. There is no way to unset it. You can use the "properties" window and uncheck a box and hit "apply", and it is SUPPOSED to unset the read-only bit, but it does not. Microsoft is aware of the problem and doesn't care. Their official answer, IIRC, is: The "read-only bit" is not what the OS checks to determine whether it can write to a directory. It's a bit that is returned to applications if they ask the OS in a certain way whether a directory is read-only. Very few applications do this; therefore, we don't care and won't fix it. Second, the permissions don't work. I have thousands of directories on my Win7 machine where the permissions are set so the current user has full control, but the current user still isn't allowed to write to the directory. Sometimes this involves symlinks, which basically don't work, and report the permissions and ownership and so on incorrectly, and inherit them in mysterious ways. |
This is not a permissions problem, and windows DOES in fact unset read-only. It's just a GUI bug that it thinks the bit is set. If you don't believe me, bring up the command prompt, cd to where the folder is, then do: dir /a:r. The folder you turned read-only off will not appear, because it really IS off. The problem is really with the system() call. Just doing this from within vim will reproduce it: The problem is because some shell like cygwin shell is being used. I put these commands at the top of my _vimrc file to solve the problem: This problem is solved now. I am not certain why this fixes it, because it seems like a race condition where the tmp file is created and closed before the process is done using it. The tmp file is in fact created successfully (I saw this with procmon), but it is closed/deleted before it's truely done with it. |
@dbeusee - thank you! That worked a treat! |
Wow! It works! I salute you. |
I know it seems like a hopeless cause, but Windows 8 has changed something to stop this fix from working when using git-bash that comes from git-scm.org. I'm trying as many possible combinations as I can but the |
What your configuration?
|
The fix for me was simply making sure |
@robmuh Still have problem? |
@dbeusee 's sloution worked for me too! |
When I run gVim (portable, 7.4) from bash (included in Git for Windows) (v2.8.3) (GNU bash, version 4.3.42(5)-release (x86_64-pc-msys)) I get in discussed problem. The Based on this issue, I have set in
Seems working. Thank you. There is no other |
If you change shell and shellcmdflag, you need to change shellxquote too. |
Variables |
Ah, if your shellquote and shellxquote is empty, it is the problem that contain spaces in the command filename as your said. |
I am sorry, I don't exactly understand. To which value should I set which of
When I set What are the correct settings, please? Which shell should be used ( It seems that only working solution with redirecting working is Thank you in advance. |
This is simply problem about executing shell command. Maybe you can solve with |
I have already solved the space in shell file name setting Other
|
win vim, it worked fine.
but in gvim, when I tried to Gist
it said:
Posting it to gist...
Error detected while processing function gist#Gist..44_GistPost:
line 63:
E484: Can't open file C:\Users\Ash\AppData\Local\Temp\VIo24B.tmp
And I looked this file, it didn't exist.
I tried with existing file, unsaved new file, results are the same.
The text was updated successfully, but these errors were encountered: