- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: vi tab/space
Operating System - HP-UX
1753522
Members
6935
Online
108795
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
Discussions
Discussions
Forums
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
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
тАО12-16-2009 03:16 PM
тАО12-16-2009 03:16 PM
HP-UX
vi Editor
I view a text file and I copy some text lines.
Then I vi other file and try to paste the copied text lines. But it includes some tabs or spaces at the beginning of each line and the structure is TOTALLY altered. This does not happen with linux vi (just to mention another case).
how can I avoid the inclusion of this tabs/spaces at the beginning of each copied line?
vi Editor
I view a text file and I copy some text lines.
Then I vi other file and try to paste the copied text lines. But it includes some tabs or spaces at the beginning of each line and the structure is TOTALLY altered. This does not happen with linux vi (just to mention another case).
how can I avoid the inclusion of this tabs/spaces at the beginning of each copied line?
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-16-2009 03:37 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-16-2009 08:24 PM
тАО12-16-2009 08:24 PM
Re: vi tab/space
It's possible your vi is running in 'autoindent' mode, which will automatically intent new lines to match the previous line. This is very useful for interactive editing, but causes problems for copy+paste.
Before pasting, try running this in the destination vi: ":set noai" (without the quotes).
autoindent seems to be the default on HP-UX vi. Linux doesn't have a standard 'vi', but on most of them, 'ai' is not the default.
BTW, if you want to read an entire file into vi, you don't need to use copy/paste, you can simply use ":r /path/to/file". This also avoids other copy+paste issues, like tabs being converted to spaces.
Before pasting, try running this in the destination vi: ":set noai" (without the quotes).
autoindent seems to be the default on HP-UX vi. Linux doesn't have a standard 'vi', but on most of them, 'ai' is not the default.
BTW, if you want to read an entire file into vi, you don't need to use copy/paste, you can simply use ":r /path/to/file". This also avoids other copy+paste issues, like tabs being converted to spaces.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2009 10:33 AM
тАО12-18-2009 10:33 AM
Re: vi tab/space
BINGO River!
The ":set noai" solved my problem.
THANK YOU!
The ":set noai" solved my problem.
THANK YOU!
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.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP