Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removes activation key: tc.Deploy no longer require an activation key #53

Merged
merged 3 commits into from Jun 19, 2020

Conversation

acmlira
Copy link
Contributor

@acmlira acmlira commented Jun 17, 2020

Long story short

Totalcross was a proprietary technology that had a system of activation keys for each dev. In early 2020 we joined the open souce movement and now that key system no longer makes sense. In these first changes we aim to:

  • Do not request a key in pom.xml;
  • Does the packaging without any key;
  • Start simulator without the activation key;
  • And have no mention of it in general use.

First user

My PC:

  • Ubuntu 18.04;
  • Kernel 5.3;

Final users

The pom.xml no longer needs <totalcross.activation_key>. Before:

<properties>
  <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  <totalcross.activation_key>${TOTALCROSSKEY}</totalcross.activation_key>
</properties>

After:

<properties>
  <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

Still in pom.xml, <build> tag no longer needs <activationKey>. Before:

<build>
  <finalName>TCSample</finalName>
  <plugins>
    <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-compiler-plugin</artifactId>
      <version>3.1</version>
      <configuration>
        <source>1.8</source>
        <target>1.8</target>
      </configuration>
    </plugin>
    <plugin>
      <groupId>com.totalcross</groupId>
      <artifactId>totalcross-maven-plugin</artifactId>
      <version>1.1</version>
      <configuration>
        <name>Sample</name>
        <platforms>
          <platform>-linux</platform>
        </platforms>
        <activationKey>${totalcross.activation_key}</activationKey>
        <!--                    For version 4.4.2 and 5.1.4 or later, Apple certificates are no longer required. -->
        <!--                    <certificates>${totalcross.applecertificate}</certificates>-->
        <totalcrossHome>~/TotalCross/sdk-deploy</totalcrossHome>
      </configuration>
      <executions>
        <execution>
          <id>post-compile</id>
          <phase>compile</phase>
          <goals>
            <goal>retrolambda</goal>
          </goals>
        </execution>
        <execution>
          <id>post-package</id>
          <phase>package</phase>
          <goals>
            <goal>package</goal>
          </goals>
        </execution>
      </executions>
    </plugin>
  </plugins>
</build>

After:

<build>
  <finalName>Sample</finalName>
  <plugins>
    <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-compiler-plugin</artifactId>
      <version>3.1</version>
      <configuration>
        <source>1.8</source>
        <target>1.8</target>
      </configuration>
    </plugin>
    <plugin>
      <groupId>com.totalcross</groupId>
      <artifactId>totalcross-maven-plugin</artifactId>
      <version>1.1</version>
      <configuration>
        <name>TCSample</name>
        <platforms>
          <platform>-linux</platform>
        </platforms>
        <!--                    For version 4.4.2 and 5.1.4 or later, Apple certificates are no longer required. -->
        <!--                    <certificates>${totalcross.applecertificate}</certificates>-->
        <totalcrossHome>~/TotalCross/sdk-deploy</totalcrossHome>
      </configuration>
      <executions>
        <execution>
          <id>post-compile</id>
          <phase>compile</phase>
          <goals>
            <goal>retrolambda</goal>
          </goals>
        </execution>
        <execution>
          <id>post-package</id>
          <phase>package</phase>
          <goals>
            <goal>package</goal>
          </goals>
        </execution>
      </executions>
    </plugin>
  </plugins>
</build>

Finally, you no longer need a key in your RunSampleApplication class, just:

public class RunSampleApplication {
  public static void main(String[] args) {
    TotalCrossApplication.run(
    Sample.class,
    "/scr",
    "1280x720");
  }
}

Next steps

The next step is to delete the RegisterSDK class and check for more implications 馃憤

- tc.Deploy no longer check/use the key but the /r option on deploy command line still can be used without errors; 
- Removes /r option from the standard help;
- DeploySettings.rasKey is no longer filled;
- GlobalConstantPool no longer provide a "free sdk limitation"
if DeploySettings.rasKey is null because TC is FOSSA
acmlira added 2 commits Jun 18, 2020
- Removes RegisterSDK because is no longer being used;
- tc.Deploy:
  - Affected by deletion of RegisterSDK
  - Fix /r case arg skip;
  - Removes FREE_BLOCKED_PLATFORMS
  - Removes Convert import (no longer used) 
- Launcher:
  - Affected by deletion of RegisterSDK
  - No longer has the key insertion screen
  - Remove /r from instructions helper
  - Remove track of TC usage
  - Fix some warnings
- Removes hasKey and isFreeSDK attributes from DeploySettings
- the above changes have affected tc.Deploy/J2TC and the errors have been corrected
@ItaloYeltsin
Copy link
Contributor

@ItaloYeltsin ItaloYeltsin commented Jun 18, 2020

haave you tested it putting the key?

@ItaloYeltsin ItaloYeltsin merged commit 37d9ffb into develop Jun 19, 2020
@ItaloYeltsin ItaloYeltsin deleted the feature/remove-activation-key branch Jun 19, 2020
flsobral pushed a commit that referenced this issue Jul 16, 2020
鈥#53)

* Removes activation key: tc.Deploy no longer require an activation key

- tc.Deploy no longer check/use the key but the /r option on deploy command line still can be used without errors; 
- Removes /r option from the standard help;
- DeploySettings.rasKey is no longer filled;
- GlobalConstantPool no longer provide a "free sdk limitation"
if DeploySettings.rasKey is null because TC is FOSSA

* Removes activation key: RegisterSDK class is no longer being used

- Removes RegisterSDK because is no longer being used;
- tc.Deploy:
  - Affected by deletion of RegisterSDK
  - Fix /r case arg skip;
  - Removes FREE_BLOCKED_PLATFORMS
  - Removes Convert import (no longer used) 
- Launcher:
  - Affected by deletion of RegisterSDK
  - No longer has the key insertion screen
  - Remove /r from instructions helper
  - Remove track of TC usage
  - Fix some warnings

* Removes activation key: DeploySettings.hasKey no longer makes sense

- Removes hasKey and isFreeSDK attributes from DeploySettings
- the above changes have affected tc.Deploy/J2TC and the errors have been corrected
flsobral pushed a commit that referenced this issue Jul 24, 2020
鈥#53)

* Removes activation key: tc.Deploy no longer require an activation key

- tc.Deploy no longer check/use the key but the /r option on deploy command line still can be used without errors; 
- Removes /r option from the standard help;
- DeploySettings.rasKey is no longer filled;
- GlobalConstantPool no longer provide a "free sdk limitation"
if DeploySettings.rasKey is null because TC is FOSSA

* Removes activation key: RegisterSDK class is no longer being used

- Removes RegisterSDK because is no longer being used;
- tc.Deploy:
  - Affected by deletion of RegisterSDK
  - Fix /r case arg skip;
  - Removes FREE_BLOCKED_PLATFORMS
  - Removes Convert import (no longer used) 
- Launcher:
  - Affected by deletion of RegisterSDK
  - No longer has the key insertion screen
  - Remove /r from instructions helper
  - Remove track of TC usage
  - Fix some warnings

* Removes activation key: DeploySettings.hasKey no longer makes sense

- Removes hasKey and isFreeSDK attributes from DeploySettings
- the above changes have affected tc.Deploy/J2TC and the errors have been corrected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants