if you don't want to make that big of change to your current code base, assuming you have:
var velocity = Vector2.ZERO
var acceleration = 10
func _physics_process(delta):
if Input.is_action_pressed("right"):
velocity.x += acceleration
velocity = move_and_slide(velocity)
For your movement code, you could simply add:
var speed_bonus = 0
func _physics_process(delta):
if Input.is_action_pressed("right"):
velocity.x += acceleration + speed_bonus
if Input.is_action_pressed("shift_run"):
speed_bonus = 10
else:
speed_bonus = 0
velocity = move_and_slide(velocity)