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

Markdown not evaluated correctly #34

Closed
via-justa opened this issue Sep 6, 2022 · 5 comments
Closed

Markdown not evaluated correctly #34

via-justa opened this issue Sep 6, 2022 · 5 comments

Comments

@via-justa
Copy link

We're sending the PR description as the body of the description and Jira does not evaluate it correctly.
In the example you can see we send > for quote and '`' to create "coded" text. We also tried sending ### for heading but it got evaluated as nested list.

Created by: "<actor name>"
PR: https://github.com/<org>/<repo>/pull/<pr number>
Description: 
Pull Request
============
>  Tracked in JIRA 

*Scope of the PR*

Add GitHub workflow to auto create Jira issue in `SRE Requests` in the following conditions:

No XXXX issue is mentioned in the subject or description when the PR is created

The user is not part of the SRE Team 

This workflow is using the following Org level secrets:

`AUTO_JIRA_ISSUE_FROM_PR` for GitHub API requests

`JIRA_USER_EMAIL` and `JIRA_API_TOKEN` for Jira API requests 

How can we instruct Jira to evaluate the body as markdown?

Action code

- name: Create
      id: create
      uses: atlassian/gajira-create@master
      if: env.CREATE_ISSUE == 'true'
      with:
        project: <project ID>
        issuetype: Task
        summary: "[PR Created] ${{ github.event.pull_request.title }}"
        description: |
          *Created by:* ${{ needs.get_actor_teams.outputs.name }}
          *PR:* https://github.com/${{ github.repository }}/pull/${{ github.event.pull_request.number }}
          *Description:* 
          ${{ github.event.pull_request.body }}
@Piedone
Copy link

Piedone commented Sep 14, 2022

You need to use the old Jira syntax. E.g. this won't work: [Does this link work?](https://lombiq.com). This will: [Or does this?|https://lombiq.com].

@via-justa
Copy link
Author

As the old Syntax is not a regular markdown and putting that structure in GitHub Issues won't look nice, are there plans to support the new markdown structure anytime soon or should we not use this action and use pure API instead?

@Piedone
Copy link

Piedone commented Sep 16, 2022

You need to use a different syntax for GitHub and Jira issues. Since Jira uses that old syntax internally, you'll need to use it in the API and also in Jira Automation (or JMWE), it's not just specific to this action.

(Note that I'm not affiliated with this project, I'm just a fellow user.)

@via-justa
Copy link
Author

Hey @Piedone thanks for the clarification. I just looked at all the gajira-* repositories and it looks like they stopped working or communicating on those repositories about 3 years ago and did not archive the repositories. Very "atlassian" of them.
I guess I'll have to switch to pure API calls.
I really would have loved to see other company provide a system in the level of Jira so we could stop doing business with that not so user oriented company (not to use a stronger language 😉 )

@via-justa
Copy link
Author

This project (like the other ghjira projects) appear to be abounded. Closing as part of issue cleanup

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

No branches or pull requests

2 participants