HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- filename globbing, IO redirection, etc.
Operating System - OpenVMS
1828625
Members
1764
Online
109983
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2005 05:56 AM
05-18-2005 05:56 AM
Buoyed by the phenomenal success of my other inquiry[0] I am now ready to tackle my next problem with the OpenVMS port of Ruby.
In DCL, filename globbing and IO redirection don't exist (and please don't point me at "HELP PIPE"; it is not a full implementation of Unix IO redirection, notably lacking "append") so scripting languages like Ruby that depend on the shell supporting this behaviour cannot be used to their full potential. When we ran up against this problem, we decided we'd look at what OpenVMS Perl does. Lo and behold, Perl does have support for this and a number of other tweaks in a file simply called "vms.c".[1]
So we borrowed bits of this code and put them in Ruby. Mind you, our initial version still has some bugs, but the transplant was, on the whole, successful.
My question is: if many different porters have to do this work over and over again, why isn't there a library supporting these "missing" operations? (I haven't looked yet to see what OpenVMS Python does -- would be interesting to compare notes.) Indeed, why doesn't the Porting Library package cover this? Seems like a logical thing to add.
Ben
[0] http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=879611
[1] http://public.activestate.com/gsar/APC/perl-current/vms/vms.c
I guess Craig "no relation to Chuck" Berry knows a little bit about this file. :)
In DCL, filename globbing and IO redirection don't exist (and please don't point me at "HELP PIPE"; it is not a full implementation of Unix IO redirection, notably lacking "append") so scripting languages like Ruby that depend on the shell supporting this behaviour cannot be used to their full potential. When we ran up against this problem, we decided we'd look at what OpenVMS Perl does. Lo and behold, Perl does have support for this and a number of other tweaks in a file simply called "vms.c".[1]
So we borrowed bits of this code and put them in Ruby. Mind you, our initial version still has some bugs, but the transplant was, on the whole, successful.
My question is: if many different porters have to do this work over and over again, why isn't there a library supporting these "missing" operations? (I haven't looked yet to see what OpenVMS Python does -- would be interesting to compare notes.) Indeed, why doesn't the Porting Library package cover this? Seems like a logical thing to add.
Ben
[0] http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=879611
[1] http://public.activestate.com/gsar/APC/perl-current/vms/vms.c
I guess Craig "no relation to Chuck" Berry knows a little bit about this file. :)
Solved! Go to Solution.
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2005 01:12 PM
05-18-2005 01:12 PM
Solution
Ben,
I'm glad you are finding Perl's getredirection() and globbing routines useful. I did not write them, though I've patched them a bit over the years. In fact I don't think they were even written for Perl originally, so you're borrowing from something that's already borrowed.
It does seem odd that the CRTL never offered this type of support. Ten years ago it was probably considered something that belonged with the now-defunct POSIX facility, and in recent years it's probably been considered something that should be handled by PIPE or perhaps GNV. In fact it's possible that the bash shell in GNV does handle redirection and globbing, though I haven't experimented with that. As Brad mentioned in the other thread, there is a product manager ready and waiting to hear the business case for putting these features in the CRTL.
An open source development that may eventually help the situation somewhat is the Parrot engine, which is destined to be the VM underneath Perl 6 and some future version of Python, and possibly Ruby as well. If this sort of thing becomes part of the VM, then the individual language implementations will be able to share it.
I'm glad you are finding Perl's getredirection() and globbing routines useful. I did not write them, though I've patched them a bit over the years. In fact I don't think they were even written for Perl originally, so you're borrowing from something that's already borrowed.
It does seem odd that the CRTL never offered this type of support. Ten years ago it was probably considered something that belonged with the now-defunct POSIX facility, and in recent years it's probably been considered something that should be handled by PIPE or perhaps GNV. In fact it's possible that the bash shell in GNV does handle redirection and globbing, though I haven't experimented with that. As Brad mentioned in the other thread, there is a product manager ready and waiting to hear the business case for putting these features in the CRTL.
An open source development that may eventually help the situation somewhat is the Parrot engine, which is destined to be the VM underneath Perl 6 and some future version of Python, and possibly Ruby as well. If this sort of thing becomes part of the VM, then the individual language implementations will be able to share it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2005 01:34 AM
05-20-2005 01:34 AM
Re: filename globbing, IO redirection, etc.
Craig,
Yes, I realize that it was borrowed already, and had the same idea to try to interest the GNV folks in the problem a while back[0], but was unable to get a response. This may have been due to bad timing, not focusing the post the right way, or simply not posting to the right forum. I posted this "OT" post to gnv-help which may not have been appropriate. There is a gnv-develop list too, but it seemed dormant, so I took my chances with gnv-help.
One of our team members here tried GNV's bash a while back and it had problems that the team judged at that time to make it unsuitable as a wrapper for Ruby. The details are fuzzy in his memory, so I'll have to look over the project document to see if they were properly recorded, but it doesn't sound encouraging.
I will have to talk to the product manager about this and the select() issue as you and Brad suggested. But I'm not holding my breath for a quick solution through that channel.
The Parrot engine does sound intriguing, too. Though again, it doesn't sound like it will be delivered in a timely enough fashion to help us out with our immediate problems. So we may end up having to kludge our way around it in the meantime. But knowledge that this is on the horizon might change our approach today in favour of a made-for-Ruby workaround until Parrot is delivered.
Ben
[0] http://sourceforge.net/mailarchive/message.php?msg_id=11179221
Yes, I realize that it was borrowed already, and had the same idea to try to interest the GNV folks in the problem a while back[0], but was unable to get a response. This may have been due to bad timing, not focusing the post the right way, or simply not posting to the right forum. I posted this "OT" post to gnv-help which may not have been appropriate. There is a gnv-develop list too, but it seemed dormant, so I took my chances with gnv-help.
One of our team members here tried GNV's bash a while back and it had problems that the team judged at that time to make it unsuitable as a wrapper for Ruby. The details are fuzzy in his memory, so I'll have to look over the project document to see if they were properly recorded, but it doesn't sound encouraging.
I will have to talk to the product manager about this and the select() issue as you and Brad suggested. But I'm not holding my breath for a quick solution through that channel.
The Parrot engine does sound intriguing, too. Though again, it doesn't sound like it will be delivered in a timely enough fashion to help us out with our immediate problems. So we may end up having to kludge our way around it in the meantime. But knowledge that this is on the horizon might change our approach today in favour of a made-for-Ruby workaround until Parrot is delivered.
Ben
[0] http://sourceforge.net/mailarchive/message.php?msg_id=11179221
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP