Cook spaghetti according to package instructions. In a large skillet, melt butter over medium heat. Add minced garlic and cook for 1 minute. Add peeled and deveined shrimp, season with salt, pepper, and a pinch of chili flakes. Cook for 2–3 minutes per side until shrimp turn pink. Toss in the cooked pasta and a squeeze of lemon juice. Garnish with chopped parsley and serve warm.