Im trying to wire this up to a button so when you press the button it prints what i want I know how to change that part its just that when i lift off and press again it doesn't print a second time
setup() does not repeat. loop() repeats. Once your message is sent the first time from setup() it will never be sent again and you sketch will be running the empty loop() over, and over, and over...
Why are you using digitalWrites on an input pin in setup()? Do you know what it's doing? I will like an answer on that question; if you don't understand, we can explain to you.
I suggest that you remove those digitalWites and change the pinMode to
pinMode(2, INTERNAL_PULLUP);
Now you need to wire the button between pin and GND and remove external pull-down resistor (if you used it).
In loop() you can now check for LOW to determine if the button is pressed and for HIGH if the button is not pressed. Your
while (digitalRead(2))
is correct for that. As long as the button is not pressed, it will read HIGH and be stuck in the while().
Last advice: get rid of magic numbers. Define/declare a pin in the beginning of your code and replace the hard-coded '2' in pinMode and digitalRead by the name of the pin.