Skip to content

Conversation

@andy-shady-org
Copy link

@andy-shady-org andy-shady-org commented Oct 21, 2016

Jain,

would you be able to add a compare function to this library at all. This would make it easy to display what have changed after an edit but before a commit is performed.

Id essentially like something like:

$queryargs{'config'} = $FinalConfig;
$res = $jnx->edit_config(%queryargs);

%queryargs = ( 'config1' => 'candidate', 'config2' => 'running' );
$diff = $jnx->compare_config(%queryargs);

print("The Difference is\n$diff");

%queryargs = ( 'comment' => 'some text here' );
$jnx->commit(%queryargs);

The output of diff could be like:

The Difference is
[ edit system services ]

  • ftp

This would be a very nice feature indeed to have :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants