(save as .mcfunction)

>>>CUSTOM FUNCTIONS:

say incoming!
execute at @p run setblock ~ ~10 ~ anvil


(yes, it's that easy: you just write each command on a different line)