andrewpalumbo commented on issue #382: [MAHOUT-2071] Fix binary and source 
releases
URL: https://github.com/apache/mahout/pull/382#issuecomment-552778835
 
 
   
   >wonder if it's trying to do something twice now, have you tried running the 
release prepare and perform steps?
   
   1. run `mvn release:prepare -Papache-release`.
   2. set all versions to `14.1`
   3. Run `mvn release:perform -Papache-release`
    - This will release Scala 2.11.8 to staging.
   
    - To then to release 2.12 artifacts (including the 
`apache-mahout-release-bin.tar.gz` disrtibution):
   4.  Delete tag from `apache/mahout` on GitBub (if necessary, the tag is 
appended by the`scala.compat.version` variable, if there is no tag from 
previous release attempts no need.), change all versions back to 
`14.1-SNAPSHOT` (they will have been changed in the Scala 2.11 release.
   5. Run `mvn release:clean -Papache-release`
   6. Find/replace all Scala versions to 2.12
   7. Run `mvn release: prepare -Papache-release`
   8. Reset all <version>s to 14.1
   9. Run `mvn release:perform -Papache-release`
   
    - The above seems a bit hacky but it seems to be a Maven Bug that causes 
some of the extra steps: 
https://github.com/Waffle/waffle/blob/master/Docs/MavenReleaseGuide.md#deploying-in-event-of-release-plugin-failure
   
   ```
   Deploying in event of release plugin failure
   The release plugin can be quite tricky. Recently, we ran into issues trying 
to use it where it would change from snapshot to the release version but then 
failed the release:prepare. As such, there is a way to get around this issue 
without much more work.
   
   If release plugin fails and versions are all essentially flagged for release 
version. Simply use this then follow the remainder of the release process.
   
   mvn deploy -Prelease
   
   After deployment in this case, make sure to set everything manually back to 
next snapshot release.
   ```
   
   
   We are required to use mvn [3.3.9).
   
   This will deploy all artifacts to staging for Scala 2.11/2.12 and Spark 
2.4.3.
   
   From the Mahout root `pom.xml`
   =======================
             <plugin>
               <groupId>org.apache.maven.plugins</groupId>
               <artifactId>maven-gpg-plugin</artifactId>
               <version>1.6</version>
               <executions>
                 <execution>
                   <id>sign-release-artifacts</id>
                   <phase>verify</phase>
                   <goals>
                     <goal>sign</goal>
                   </goals>
                   <configuration>
                     <keyname>${gpg.keyname}</keyname>
                     <passphraseServerId>${gpg.passphrase}</passphraseServerId>
                   </configuration>
                 </execution>
               </executions>
             </plugin>```
   
   You'll need to add settings for the following in your `~/.m2/settings.xml`
   ```
   <keyname>${gpg.keyname}</keyname>
   <passphraseServerId>${gpg.passphrase}</passphraseServerId>
   ```
   
   E.g.:
   
   ```
      <profiles>
         <profile>
          <id>apache-release</id>
          <properties>
                <gpg.keyname>ABC123</gpg.keyname>
                <gpg.passphrase>1234</gpg.passphrase>
                
<deploy.altRepository>mahout.releases::default::https://repository.apache.org/service/local/staging/deploy/maven2/</deploy.altRepository>
               
<url>https://repository.apache.org/service/local/staging/deploy/maven2/</url>
          </properties>
          </profile>
          <profile>
           <activation>
             <activeByDefault>true</activeByDefault>
           </activation>
           <properties>
          <gpg.keyname>ABC123</gpg.keyname>
           </properties>
         </profile>
       </profiles>
       <servers>
         <!-- To publish a snapshot to Maven -->
         <server>
           <id>apache.snapshots.https</id>
           <username>nobody</username>
        <password>nobodysASF-LDAPpassword</password>
        </server>

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to