Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Next: , Previous: Exiting Emerge, Up: Emerge


33.3.6 Combining the Two Versions

Sometimes you want to keep both alternatives for a particular difference. To do this, use x c, which edits the merge buffer like this:

     #ifdef NEW
     version from A buffer
     #else /* not NEW */
     version from B buffer
     #endif /* not NEW */

While this example shows C preprocessor conditionals delimiting the two alternative versions, you can specify the strings to use by setting the variable emerge-combine-versions-template to a string of your choice. In the string, ‘%a’ says where to put version A, and ‘%b’ says where to put version B. The default setting, which produces the results shown above, looks like this:

     "#ifdef NEW\n%a#else /* not NEW */\n%b#endif /* not NEW */\n"

 
 
  Published under the terms of the GNU General Public License Design by Interspire