I'm trying to find a way how to conveniently edit(and pass) multi-line arguments to org-babel block.
In the example below, ${name} variable is pretty convenient to edit as inline variable but for ${storyDescription} it becomes very annoying because it could contain dozens of lines(separated by \n) and I would like to manage it like a regular text.
#+BEGIN_SRC http :pretty :var projectId="123" :var name="Test story name"
POST https://www.pivotaltracker.com/services/v5/projects/${projectId}/stories
X-TrackerToken: ${token}
Content-Type: application/json
{
"name": ${name},
"description": ${storyDescription},
"current_state": "unstarted",
"estimate": 1
}
#+END_SRC
Any hints are greatly appreciated.
Update.
For now, I'm using the following(dirty) hack in Ruby:
#+name: storyDescription
#+BEGIN_SRC ruby :results value
<<-EOL.gsub("\n", "\\n")
first line
second line
EOL
#+END_SRC
#+RESULTS: storyDescription
: first line\nsecond line\n
it works but I'm happy to accept more clean and idiomatic solution to this.
I'm wondering why there isn't some kind of BEGIN_SRC text
(org-babel "text" language that's used just for setting long content blocks of plain text).