https://rt-wiki.bestpractical.com/index.php?title=Zenity_quick_ticket_script&feed=atom&action=historyZenity quick ticket script - Revision history2024-03-29T02:13:29ZRevision history for this page on the wikiMediaWiki 1.37.2https://rt-wiki.bestpractical.com/index.php?title=Zenity_quick_ticket_script&diff=4320&oldid=prevAdmin: 1 revision imported2016-04-06T20:39:47Z<p>1 revision imported</p>
<p><b>New page</b></p><div><br />
With this script you can easily create a ticket say with a click on Your taskbar in gnome.<br />
<br />
You can enter a subject and comment on it.<br />
<br />
I handy tool for unplanned interruptions when working with the Pomodoro Technique.<br />
<pre><br />
#!/bin/bash<br />
<br />
#Unplanned not urgent interruptions:<br />
inp=$(zenity --entry --title="Note" --width=80 --text="Type subject...");<br />
if [ "$inp" = "" ]; then<br />
echo no input - exiting<br />
exit<br />
else<br />
ticket=$(rt create -t ticket set Subject="Unplanned,NotUrgent: $inp" set Queue=Diverse set Priority=0|awk '{print $3}')<br />
echo $ticket<br />
fi<br />
zenity --question --text="You want to add additional comment to ticket?"<br />
if [ "$?" -eq 0 ]; then<br />
inp=$(zenity --entry --title=Comment on ticket" --width=80 --text="Please enter comment");<br />
if [ "$inp" = "" ]; then<br />
exit<br />
fi<br />
rt comment -m "$inp" $ticket<br />
else<br />
exit<br />
fi<br />
<br />
</pre></div>Admin