Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 16 Nov 2018, 22:42
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [1 Post]  
Author Message

Joined: 30 May 2010
Posts: 2362
Location: Queensland

PostPosted: Tue 17 Jan 2017, 22:33    Post subject:  EDLN
Subject description: edln allows a existing symlink destination to be changed

I found this as a solution to a problem of changing symlinks when repackaging.

Usage edln /path/to/symlink /symlink/target


edln is a simple readline-based utility for interactively editing the target
of a symbolic link. This is most useful if you only need to make a relatively
minor change to the symlink.

Using edln

Typically, edln is called with a single argument -- the path to the symlink
to be edited. For example, if you have a symlink 'foo' that points to the
file '/usr/local/bin/foo-1.0', and you want to update it to point to the file
'/usr/local/bin/foo-1.1' instead, you would invoke edln as follows (where the
'$' denotes the shell prompt):

$ edln foo
New target: /usr/local/bin/foo-1.0

As you can see, edln displays the current symlink target, and allows you to
edit it. Now press the Backspace key once to delete the '0' character, then
press the '1' key to insert the '1' character, and finally, press the Enter
key to complete the update.

As edln relies on GNU Readline for editing, it supports much more
sophisticated editing than demonstrated in the simple example above.
Refer to the GNU Readline User Manual for further details:


As a final note, edln also supports a two-argument invocation, which is
mostly equivalent to 'ln -sf'. That is, 'edln foo /usr/local/bin/foo-1.1' has
the same effect as 'ln -sf /usr/local/bin/foo-1.1 foo'.

However, when the symlink 'foo' points to a directory, the behavior is
different. For example, suppose 'foo' points to 'dir1', and you want to
change it to point to 'dir2' instead. Running 'ln -sf dir2 foo' will not
accomplish this -- instead, it will create inside 'dir1' a new symlink 'dir2'
(that points to 'dir2'). In contrast, running 'edln foo dir2' will have the
desired effect.

Pre-Built Binaries

Binaries for select platforms are available at:


For other platforms, edln should not be difficult to build from source.

Building From Source

A simple makefile is provided with the edln source code, available at:


You need to ensure that the GNU Readline development packages are installed
(e.g., 'libreadline-dev' on Debian/Ubuntu, or 'readline-devel' on RHEL/CentOS).

You may also need to ensure that the GNU Ncurses package is installed,
particularly on RHEL/CentOS, where linking with the -lncurses flag is
required. On RHEL/CentOS, the package name is 'ncurses'.

Exact details for building from source on other Unix-like systems may vary,
but should be quite similar.
 Filesize   47.5 KB
 Viewed   129 Time(s)


Description  Binary compiled in Tahr

Filename  edln.tar.gz 
Filesize  3.2 KB 
Downloaded  101 Time(s) 

Filename  edln-master.zip 
Filesize  4.23 KB 
Downloaded  71 Time(s) 

Carolina: Recent Repository Additions

Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [1 Post]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum

Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1482s ][ Queries: 15 (0.0610s) ][ GZIP on ]