Looking for help with basic macro

Hello folks,

I’m trying to figure out how to make a simple GS that will do the following.

Cast Immolation Aura if off cd
Cast Felblade if off cd
Cast Sheer otherwise

Can anyone help? I’ve been having a lot of trouble getting this to work as desired.

Thanks =)

Sequences['whatever'] = {
/console Sound_EnableSFX 0
/targetenemy [noharm][dead]
[[/cast [combat] Immolation Aura]],
[[/cast [combat] Felblade]],
[[/cast [combat] Sheer]],
PostMacro = [[
/script UIErrorsFrame:Hide();
/console Sound_EnableSFX 1

I dont know if I’m doing this right, because sometimes it won’t work properly and immolation will stay off cooldown for like 2 seconds. It seems like whenever I press the button, it’s looking to do what’s next in the rotation. I was looking for something I could just mindlessly spam. what’s the correct way to import this into gse?