Cursor can't run AWS commands

URGENT (i’ve heard the same issue from many friends, and the only reason i use windsurf instead of cursor right now is this bug.)

bug: cursor can’t run (or read the output of) aws commands. i believe cursor ends each command with a ‘| head’. this breaks most of the aws commands. this is because aws command outputs use a pager interface with interactive navigation. this makes cursor almost completely unusable for projects involving aws deployments.

to reproduce: have cursor run standard aws commands, like listing resources.

I’m using the most recent Cursor version.

thats probably because running those commands normally goes into a vim-like mode I think somehing called less and since it expects output from you after entering that mode, the agent fails. and I think you only see these in commands with longer output.

I think you have two options.

a) use this command to disable it globally: aws configure set cli_pager

b) try forcing ai to pipe and cat the problematic commands. you can use cursor rules to force the agent to always pipe and cat. just try asking the agent to append a “| cat” at the end of the command and see if it works

I recommend option 2 with some project level rules as I don’t like messing up with aws cli defaults.

let me know if it works!

1 Like

configuring aws is the perfect solution. thanks, deniz :slight_smile:

my workaround that i had been using for months now was a simple aws cli wrapper (executable bash script in my path).

1 Like