Journals consider that is good practice to release script and codes to repeat the published results, and many of us I think agree with this practice. Code are typically deposited in software version control repositories (e.g., GitHub or BitBucket).
I wonder if updating the codes during reviewing process or after publications (which in my opinion is quite important, in general) remains a good practice. Maybe the obvious answer is yes, but for example it is certainly not good to modify the data deposited for a published article (or modify its pre-print in a pre-print server).