I was hoping to use netrw.vim to view members in a z/OS PDS, but I
cannot quite get the format of the URL correct. (Windows XP; Vim 7.2,
Big version with GUI)

I first tried

:e ftp://usern...@hostname/HLQ.PDS(MEMBER)

As expected, the z/OS ftp daemon prepends my username and looks for
USERNAME.HLQ.PDS(MEMBER) which is not going to be found.

So, I tried it with single quotes (z/OS convention):

:e ftp://usern...@hostname/'HLQ.PDS(MEMBER)'

No joy. The netrw debug tab contains a lot of information, but it
looks like the local name has a trailing \' (backslash, single quote),
which I think is the source of the problem here. I can see the the ftp
daemon found the member and was happy to send, but the local filename
was unacceptable because of the backslash and so, could not be opened.

If there is a more specific location to ask about netrw.vim, I'll
happily take my question there.

FWIW, if I want to open USERNAME.PDS(MEMBER), that works:

:e ftp://usern...@hostname/PDS(MEMBER)

So, it seems limited to just the times when I need the single quotes
to prevent the prepending of my username.

Fuzzy
-- 
Latin: Dum spiro spero.
English: While I breathe, I hope.

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

---------
Decho Tab C:\Program Files\Vim\vim72\autoload\netrw.vim
---------
doing autoload/netrw.vim version v132
ssh is not executable
netrw#NetrwSavePosn() {
|netrw#NetrwRestorePosn() a:0=0 winnr=1 line=1 col=1 hline=1 {
||restore window: exe silent! 1wincmd w
||restore topofscreen: exe norm! 1G0z
||restore posn: exe norm! 1G01|
||return netrw#NetrwRestorePosn }
|return netrw#NetrwSavePosn : winnr=1 line=1 col=1 hline=1 }
netrw#NetRead(mode=2,...) a:0=1 v132 {
|s:NetrwOptionSave(vt<w:>) win#1 
buf#1<ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'> {
||w:netrw_optionsave doesn't exist
||fo=tcq acd=0
||return s:NetrwOptionSave : win#1 buf#1 }
|s:NetrwSafeOptions() win#1 buf#1<ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'> {
||window's ft=
||fo=nroql2 acd=0
||return s:NetrwSafeOptions }
|readcmd<%r> ichoice=1
|s:GetTempfile(fname<>) {
||tmpfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.tmp> : from tempname()
||tmpfile<C:/DOCUME~1/localusr/LOCALS~1/Temp/VIAA8F.tmp> : chgd any \ -> /
||tmpfile<C:/DOCUME~1/localusr/LOCALS~1/Temp/VIAA8F.tmp> 
s:netrw_tmpfile<C:/DOCUME~1/localusr/LOCALS~1/Temp/VIAA8F.tmp>
||o/s dependent fixed tempname<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.tmp>
||ro=0 ma=1 mod=0 wrap=0
||return s:GetTempfile <C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.tmp> }
|no lastfile: choice<ftp://usern...@hostname/\'HLQ.PDS(MEMBER)\'>
|choice<ftp://usern...@hostname/\'HLQ.PDS(MEMBER)\'>
|NetrwMethod(a:choice<ftp://usern...@hostname/\'HLQ.PDS(MEMBER)\'>) {
||determine method:
||ftp://...
||s:FileReadable(fname<C:\Documents and Settings\localusr\.netrc>) {
|||return s:FileReadable 0 }
||NetUserPass(a:1<USERNAME>) { {
|||a:0=1 case <=1:
|||return NetUserPass }
||a:choice       <ftp://usern...@hostname/\'HLQ.PDS(MEMBER)\'>
||b:netrw_method <3>
||g:netrw_machine<hostname>
||g:netrw_port   <>
||g:netrw_uid    <USERNAME>
||s:netrw_passwd <thepassword>
||b:netrw_fname  <\'HLQ.PDS(MEMBER)\'>
||return NetrwMethod : b:netrw_method=3 }
|s:GetTempfile(fname<\'HLQ.PDS(MEMBER)\'>) {
||tmpfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.tmp> re-using
||using fname<\'HLQ.PDS(MEMBER)\'>'s suffix
||suffix<.PLX(MEMBER)\'>
||chgd tmpfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F> (removed any .tmp 
suffix)
||chgd tmpfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'> (added 
.PLX(MEMBER)\' suffix) netrw_fname<\'HLQ.PDS(MEMBER)\'>
||ro=0 ma=1 mod=0 wrap=0
||return s:GetTempfile 
<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'> }
|checking if NetrwBrowse() should handle 
choice<ftp://usern...@hostname/\'HLQ.PDS(MEMBER)\'> with netrw_list_cmd<>
|read via ftp+mipf (method #3)
|s:SaveBufVars() {
||return s:SaveBufVars }
|s:RestoreBufVars() {
||return s:RestoreBufVars }
|filter input: open hostname
|filter input: user "USERNAME" "thepassword"
|filter input: ascii
|filter input: get "\'HLQ.PDS(MEMBER)\'" 
C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'
|executing: %!ftp -i -n
|error<Error opening local file 
C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'.^M>
|netrw#ErrorMsg(level=2 msg<Error opening local file 
C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'.^M> errnum=5) 
g:netrw_use_errorwindow=1 {
||level=**error** (netrw) 
||s:winBeforeErr=1
||create a NetrwMessage buffer window
||setlocal ma noro
||wrote msg<**error** (netrw) Error opening local file 
C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'.^M> to NetrwMessage 
win#3
||return netrw#ErrorMsg }
|s:SaveBufVars() {
||return s:SaveBufVars }
|s:RestoreBufVars() {
||return s:RestoreBufVars }
|NetrwGetFile(readcmd<%r>,tfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'>
 method<3>) {
||rfile<ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'>
||get file into buffer
||exe silent! keepalt file 
C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\\'
||edit temporary file
||exe silent! keepalt file ftp:\\usern...@hostname\\'HLQ.PDS(MEMBER)\'
||renamed buffer back to remote 
filename<ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'> : 
expand(%)<ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'>
||redir<ls!>: 
||redir<ls!>:   1 %a   "ftp:\\usern...@hostname\'HLQ.PDS(MEMBER)'" line 1
||redir<ls!>:   2u a-  "Decho Tab"                    line 0
||redir<ls!>:   3  a + "[No Name]"                    line 1
||redir<ls!>:   6u     "C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)'" 
line 1
||NetReadFixup() not called, doesn't exist  (line1=1 line2=1)
||s:UpdateBuffersMenu() {
|||return s:UpdateBuffersMenu }
||s:FileReadable(fname<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'>)
 {
|||return s:FileReadable 0 }
||readcmd<%r> cmdarg<> 
tfile<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'> readable=0
||ro=0 ma=1 mod=0 wrap=0
||return NetrwGetFile }
|cleanup b:netrw_method and b:netrw_fname
|s:FileReadable(fname<C:\DOCUME~1\localusr\LOCALS~1\Temp\VIAA8F.PLX(MEMBER)\'>) 
{
||return s:FileReadable 0 }
|s:NetrwOptionRestore(vt<w:>) win#2 buf#1 {
||g:netrw_keepdir=1: getcwd<C:\Documents and Settings\localusr> acd=0
||g:netrw_keepdir=1: getcwd<C:\Documents and Settings\localusr> acd=0
||fo=tcq acd=0
||ro=0 ma=1 mod=0 wrap=0
||return s:NetrwOptionRestore : win#2 buf#1 }
|return netrw#NetRead :5 getcwd<C:\Documents and Settings\localusr> }
netrw#NetrwRestorePosn() a:0=0 winnr=1 line=1 col=1 hline=1 {
|restore window: exe silent! 1wincmd w
|return netrw#NetrwRestorePosn }

Reply via email to