Ho sentito dire in diversi punti "Non commettere grandi commit", ma non ho mai realmente capito che cosa è un "grande" commit. È grande se lavori su un mucchio di file anche se ci sono in relazione? In quante parti di un progetto dovresti lavorare contemporaneamente?
Per me, ho difficoltà a cercare di fare "piccoli commit" poiché dimentico o creo qualcosa che crea qualcos'altro che crea qualcos'altro. Finisci con cose del genere:
Made custom outgoing queue Bot -New field msgQueue which is nothing more than a SingleThreadExecutor -sendMsg blocks until message is sent, and adds wait between when messages get sent -adminExist calls updated (see controller) -Removed calles to sendMessage Controller -New field msgWait denotes time to wait between messages -Starting of service plugins moved to reloadPlugins -adminExists moved from Server because of Global admins. Checks at the channel, server, and global level Admin -New methods getServer and getChannel that get the appropiate object Admin belongs to BotEvent -toString() also show's extra and extra1 Channel -channel field renamed to name -Fixed typo in channel(int) Server -Moved adminExists to Controller PluginExecutor -Minor testing added, will be removed later JS Plugins -Updated to framework changes -Replaced InstanceTracker.getController() with Controller.instance -VLC talk now in own file Various NB project updates and changes --- Affected files Modify /trunk/Quackbot-Core/dist/Quackbot-Core.jar Modify /trunk/Quackbot-Core/dist/README.TXT Modify /trunk/Quackbot-Core/nbproject/private/private.properties Modify /trunk/Quackbot-Core/nbproject/private/private.xml Modify /trunk/Quackbot-Core/src/Quackbot/Bot.java Modify /trunk/Quackbot-Core/src/Quackbot/Controller.java Modify /trunk/Quackbot-Core/src/Quackbot/PluginExecutor.java Modify /trunk/Quackbot-Core/src/Quackbot/info/Admin.java Modify /trunk/Quackbot-Core/src/Quackbot/info/BotEvent.java Modify /trunk/Quackbot-Core/src/Quackbot/info/Channel.java Modify /trunk/Quackbot-Core/src/Quackbot/info/Server.java Modify /trunk/Quackbot-GUI/dist/Quackbot-GUI.jar Modify /trunk/Quackbot-GUI/dist/README.TXT Modify /trunk/Quackbot-GUI/dist/lib/Quackbot-Core.jar Modify /trunk/Quackbot-GUI/nbproject/private/private.properties Modify /trunk/Quackbot-GUI/nbproject/private/private.xml Modify /trunk/Quackbot-GUI/src/Quackbot/GUI.java Modify /trunk/Quackbot-GUI/src/Quackbot/log/ControlAppender.java Delete /trunk/Quackbot-GUI/src/Quackbot/log/WriteOutput.java Modify /trunk/Quackbot-Impl/dist/Quackbot-Impl.jar Modify /trunk/Quackbot-Impl/dist/README.TXT Modify /trunk/Quackbot-Impl/dist/lib/Quackbot-Core.jar Modify /trunk/Quackbot-Impl/dist/lib/Quackbot-GUI.jar Modify /trunk/Quackbot-Impl/dist/lib/Quackbot-Plugins.jar Modify /trunk/Quackbot-Impl/lib/javarebel.stats Add /trunk/Quackbot-Impl/lib/jrebel.info Modify /trunk/Quackbot-Impl/nbproject/private/private.properties Modify /trunk/Quackbot-Impl/nbproject/private/private.xml Modify /trunk/Quackbot-Impl/nbproject/project.properties Modify /trunk/Quackbot-Impl/plugins/CMDs/Admin/reload.js Add /trunk/Quackbot-Impl/plugins/CMDs/Operator/hostBan Modify /trunk/Quackbot-Impl/plugins/CMDs/Operator/mute.js Modify /trunk/Quackbot-Impl/plugins/CMDs/lyokofreak/curPlaying.js Modify /trunk/Quackbot-Impl/plugins/CMDs/lyokofreak/lfautomode.js Modify /trunk/Quackbot-Impl/plugins/listeners/onJoin.js Modify /trunk/Quackbot-Impl/plugins/listeners/onQuit.js Modify /trunk/Quackbot-Impl/plugins/testCase.js Add /trunk/Quackbot-Impl/plugins/utils/whatsPlaying.js Modify /trunk/Quackbot-Impl/src/Quackbot/impl/SandBox.java Add /trunk/Quackbot-Impl/vlc_http Add /trunk/Quackbot-Impl/vlc_http/current.html Modify /trunk/Quackbot-Plugins/dist/Quackbot-Plugins.jar Modify /trunk/Quackbot-Plugins/dist/README.TXT Modify /trunk/Quackbot-Plugins/dist/lib/Quackbot-Core.jar Modify /trunk/Quackbot-Plugins/nbproject/private/private.properties Modify /trunk/Quackbot-Plugins/nbproject/private/private.xml Modify /trunk/Quackbot-Plugins/src/Quackbot/plugins/JSPlugin.java Add /trunk/Quackbot-Plugins/vlc_http Add /trunk/global-lib/jrebel.jar
Sì ....
Quindi per domande:
- Quali sono alcuni fattori per quando un commit diventa troppo grande ( cose non ovvie )?
- Come puoi evitare tali commit? Si prega di fornire specifiche
- Che dire di quando sei alle prime fasi dello sviluppo quando le cose si muovono velocemente? I commit enormi sono ancora a posto?