Teach your dog to bark only to alert you and to then stop barking afterwards.
If your dog barks at everything that moves, use short reprimand words.
If you do the same every time your dog does something wrong, it will soon understand. Praise your dog as soon as it stops barking.
Do not console a barking dog. This will reward or reinforce barking.
Puppies bark for a wide range of reasons as they mature. It is part of their natural development.
If you train your dog well, it will not become a nuisance barker.
Training advice on getting your dog to stop barking is available in this article.