Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

User-accessible way to get a task-id?

Tags:

asana

I want to make a git hook that will automatically comment on an open issue in asana when someone makes a commit with a specially-formatted message. Something along the lines of:

asana task-id: Fix whatever

The main problem I'm having is I don't know an easy way of getting the task-id. The ids are quite long and the only place I see them being displayed in the user interface is in the URL when you click a task. This is a bit cumbersome and error prone when trying to copy it, and isn't obvious to the user.

Is there an easier way to comment on a task from a shell script (or git hook)?

like image 733
eresonance Avatar asked Jan 27 '14 22:01

eresonance


People also ask

How do I find my task ID?

To get the task ID of the currently executing task from within code that task is executing, use the CurrentId property.

What is task ID?

Description The Task ID field contains the number that Project assigns to each task as you add it to the project. The Task ID indicates the position of the task with respect to the other tasks. How Calculated As you create tasks, Project automatically assigns the next number in the sequence of tasks as listed.


Video Answer


1 Answers

Well, regardless of how you do it you'd definitely need the task ID (as you pointed out, it's in the URL). What we actually do internally is just paste a link to an Asana task - it contains the ID, identified it as an asana task, and is clickable in many views so you can jump right to the task it's talking about when viewing commit history. Very handy!

We then have what is essentially a commit hook look for https://app.asana.com/..., grab the task ID and post a new comment linking to the commit in our source control and the commit message.

Using URLs means the link goes both ways, which is incredibly convenient.

like image 164
agnoster Avatar answered Oct 11 '22 06:10

agnoster