Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fn strip-margin #3

Merged
merged 1 commit into from
Sep 8, 2021

Conversation

danielmiladinov
Copy link
Contributor

Similar to String.stripMargin extension method in Scala; e.g.:

(require '[yang.lang :as yl])
=> nil

(println
  (yl/strip-margin "|<?xml version='1.0' encoding='utf-8'?>
                    |<people>
                    |  <person>
                    |    <name>Joe Smith</name>
                    |  </person>
                    |</people>"))
<?xml version='1.0' encoding='utf-8'?>
<people>
  <person>
    <name>Joe Smith</name>
  </person>
</people>
=> nil

Signed-off-by: Daniel Miladinov daniel.miladinov@gmail.com

Copy link
Owner

@tolitius tolitius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the PR!

src/yang/lang.clj Outdated Show resolved Hide resolved
Signed-off-by: Daniel Miladinov <daniel.miladinov@gmail.com>
@tolitius
Copy link
Owner

tolitius commented Sep 8, 2021

thank you!

@tolitius tolitius merged commit 4f92fd4 into tolitius:master Sep 8, 2021
@danielmiladinov danielmiladinov deleted the add-fn-strip-margin branch September 8, 2021 14:01
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.

2 participants