Cook the spaghetti or linguine according to package instructions until al dente. Drain and set aside.
In a large skillet or wok, heat the vegetable oil over medium heat. Add the minced garlic and red pepper flakes, and sauté for about 30 seconds until fragrant.
Stir in the soy sauce, oyster sauce (if using), rice vinegar, and sugar. Mix well and let it simmer for 1-2 minutes.
Add the cooked noodles to the skillet, tossing to coat them evenly in the sauce. Cook for an additional 2-3 minutes, stirring frequently.
Remove from heat and stir in the chopped green onions. Serve hot, garnished with sesame seeds if desired.