Exist a way to save dialplan from CLI?

Exist a way to add extension to dialplan from CLI but without loose the comments in extensions.conf?