git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Eyjolfur Eyjolfsson <eyjolfureyjolfsson@tprg.com>
To: "Randall S. Becker" <rsbecker@nexbridge.com>
Cc: Kevin Daudt <me@ikke.info>, git@vger.kernel.org
Subject: Re: Is it possible to convert a Json file to xml file with Git
Date: Wed, 1 Nov 2017 10:09:34 +0000	[thread overview]
Message-ID: <CAO-WtQheY-cpBwEp1TGbRAT4t7Ao7qDdGdinMBb2eB6AOeuKBA@mail.gmail.com> (raw)
In-Reply-To: <001801d35292$9871bd10$c9553730$@nexbridge.com>

Hi

Thank you for your response and help. I am new to Git.
The reason for my question is that I am using Git or Bash.exe  (cURl)
to call a REST web service (open for test) and retrieving  Json
from the web service and storing it into file.
This works fine from the Git Bash command line . My Git Command:
$ curl https://jsonplaceholder.typicode.com/posts -o c:\temper.txt

I will look into the smudge filter.

One more question is there a possibility to call Git Bash with a
parameter like example
C:\Git\Git\git-bash.exe  curl
https://jsonplaceholder.typicode.com/posts -o c:\temper.txt

The reason I am asking this is that I am using NAV 2009 Classic Client
and want to lunch the Git Bash with
 the command  $ curl https://jsonplaceholder.typicode.com/posts -o c:\temper.txt


Best regards

(e) eyjolfureyjolfsson@tprg.com
(w) tpretailgroup.com


On 31 October 2017 at 21:52, Randall S. Becker <rsbecker@nexbridge.com> wrote:
>> On October 31, 2017 5:23 PM, Kevin Daudt wrote:
>> > On Tue, Oct 31, 2017 at 05:28:40PM +0000, Eyjolfur Eyjolfsson wrote:
>> > I have a question.
>> > Is it possible to convert a Json file to XML with Git
>>
>> git is a version control system, which is mostly content agnostic. It
> knows
>> nothing about json or xml, let alone how to convert them.
>>
>> You might want to use some kind of programming language to do the
>> conversion.
>
> Speculating... one possible reason to do this is during a protocol
> conversion effort, where definitions are moving from XML to JSON form. In
> legacy VCS systems, keeping interface definitions in one file and converting
> the content may be important. However, in git, with its concept of atomicity
> (multiple files are committed in a single version across the whole
> repository), dropping one file (e.g., XML) and adding another (e.g., JSON),
> can be done in one commit, and never lost or confused as to what is
> intended. This makes git ideal for modernization and evolutionary projects.
>
> If, however, there is an application or systemic requirement to change the
> content of a file from XML to JSON without changing the name - I've seen it
> happen - you may want to consider building a smudge filter that understands
> the difference and maps between the two, to allow git diff operations
> between old and new formats. I would not recommend using this approach
> except as a last possible resort. Make a new file as Kevin intimated.
>
> Just Musing on the Topic,
> Randall
>
> -- Brief whoami: NonStop&UNIX developer since approximately
> UNIX(421664400)/NonStop(211288444200000000)
> -- In my real life, I talk too much.
>
>
>



-- 
Eyjolfur Eyjolfsson

(e) eyjolfureyjolfsson@tprg.com
(w) tpretailgroup.com

-- 
This email and any files transmitted with it are confidential and intended 
for the sole use of the individual or entity to whom they are addressed. 
 Any unauthorised dissemination or copying of this email or its attachments 
or disclosure of any information contained in them is strictly prohibited. 
 If you have received the email in error, please notify the sender by email 
immediately and delete it from your system.  The content of the email does 
not necessarily represent Theo Paphitis Retail Group and associated 
companies and any views or opinions presented are solely those of the 
author.  Whilst we check communications we send for virus infection, you 
should check this email and any attachments to it for viruses as we accept 
no responsibility for any loss or damage caused by any virus transmitted by 
this email.  Email transmission cannot be guaranteed secure or error-free.

Theo Paphitis Retail Group is the collective name for Ryman Group Limited, 
registered in England and Wales, Company Number 02714395, VAT Number 
672523729,  Registered Office: Ryman House, Savoy Road, Crewe, Cheshire, 
CW1 6NA; Ryman Limited, registered in England and Wales, Company Number 
3007166, VAT Number 672523729,  Registered Office: Ryman House, Savoy Road, 
Crewe, Cheshire, CW1 6NA;  Robert Dyas Holdings Limited, registered in 
England and Wales, Company Number 4041884; VAT number 742720153, Registered 
Office:  1 St George’s Road, Wimbledon, London, SW19 4DR;  Boux Avenue 
Limited, registered in England and Wales, Company Number 7191520, VAT 
Number 125504638,  Registered Office: 1 St George’s Road, Wimbledon, 
London, SW19 4DR;  Boux Avenue International Limited, registered in England 
and Wales, Company Number 8047333, VAT Number 125504638, Registered office: 
1 St George’s Road, Wimbledon, London, SW19 4DR; and London Graphic Centre 
Limited, registered in England and Wales, Company Number 6062021,  VAT 
Number 251820524, Registered Office:  Ryman House, Savoy Road, Crewe, 
Cheshire, CW1 6NA.

  reply	other threads:[~2017-11-01 10:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-31 17:28 Is it possible to convert a Json file to xml file with Git Eyjolfur Eyjolfsson
2017-10-31 21:22 ` Kevin Daudt
2017-10-31 21:52   ` Randall S. Becker
2017-11-01 10:09     ` Eyjolfur Eyjolfsson [this message]
2017-11-01 10:25       ` Jason Pyeron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAO-WtQheY-cpBwEp1TGbRAT4t7Ao7qDdGdinMBb2eB6AOeuKBA@mail.gmail.com \
    --to=eyjolfureyjolfsson@tprg.com \
    --cc=git@vger.kernel.org \
    --cc=me@ikke.info \
    --cc=rsbecker@nexbridge.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).