Skip to content

Commit

Permalink
v0.5.4
Browse files Browse the repository at this point in the history
fix inspections
  • Loading branch information
thevpc committed Apr 21, 2019
1 parent be1f38a commit 8056945
Show file tree
Hide file tree
Showing 57 changed files with 1,143 additions and 1,810 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Network Updatable Things Services
/ | / /_ __/ /______
/ |/ / / / / __/ ___/
/ /| / /_/ / /_(__ )
/_/ |_/\__,_/\__/____/ version 0.5.3.0
/_/ |_/\__,_/\__/____/ version 0.5.4.0
</pre>

nuts stands for **Network Updatable Things Services** tool. It is a simple tool for managing remote
Expand All @@ -30,7 +30,7 @@ to install and uninstall components allowing multiple versions of the very same
+ find : searches for existing/installable components

## Download Latest stable version
+ Java or any Java enabled OS : Linux,Windows,iOS, ... :: [nuts-0.5.3.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.3/nuts-0.5.3.jar)
+ Java or any Java enabled OS : Linux,Windows,iOS, ... :: [nuts-0.5.4.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.4/nuts-0.5.4.jar)

## Requirements
Java Runtime Environment (JRE) or Java Development Kit (JDK) version 8 or later
Expand Down Expand Up @@ -61,6 +61,7 @@ java -jar nuts-0.5.4.jar

## Latest News

+ 2019/04/21 nuts 0.5.4.0 released [nuts-0.5.3.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.4/nuts-0.5.4.jar)
+ 2019/01/05 nuts 0.5.3.0 released [nuts-0.5.3.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.3/nuts-0.5.3.jar)
+ 2018/12/28 nuts 0.5.2.0 released [nuts-0.5.2.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.2/nuts-0.5.2.jar)
+ 2018/12/18 nuts 0.5.1.0 released [nuts-0.5.1.jar](https://github.com/thevpc/vpc-public-maven/raw/master/net/vpc/app/nuts/nuts/0.5.1/nuts-0.5.1.jar)
Expand Down
6 changes: 3 additions & 3 deletions nuts-core/nbactions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<goal>org.codehaus.mojo:exec-maven-plugin:1.2.1:exec</goal>
</goals>
<properties>
<exec.args>-Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --init=reset -y find -f local --lenient --json</exec.args>
<exec.args>-Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --exec --show-command vr-box</exec.args>
<exec.executable>java</exec.executable>


Expand Down Expand Up @@ -38,7 +38,7 @@
<goal>org.codehaus.mojo:exec-maven-plugin:1.5.0:exec</goal>
</goals>
<properties>
<exec.args>-Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --init=reset -y find -f local --lenient --json</exec.args>
<exec.args>-Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --exec --show-command vr-box</exec.args>
<exec.executable>java</exec.executable>
</properties>
</action>
Expand All @@ -52,7 +52,7 @@
<goal>org.codehaus.mojo:exec-maven-plugin:1.5.0:exec</goal>
</goals>
<properties>
<exec.args>-agentlib:jdwp=transport=dt_socket,server=n,address=${jpda.address} -Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --init=reset -y find -f local --lenient --json</exec.args>
<exec.args>-agentlib:jdwp=transport=dt_socket,server=n,address=${jpda.address} -Dnuts.export.trace-exit-errors=y -classpath %classpath net.vpc.app.nuts.Nuts --exec --show-command vr-box</exec.args>
<exec.executable>java</exec.executable>
<jpda.listen>true</jpda.listen>
</properties>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,11 @@
import java.util.HashSet;
import java.util.Set;
import net.vpc.app.nuts.NutsAddUserCommand;
import net.vpc.app.nuts.NutsCommandArg;
import net.vpc.app.nuts.NutsCommandLine;
import net.vpc.app.nuts.NutsIllegalArgumentException;
import net.vpc.app.nuts.NutsRepository;
import net.vpc.app.nuts.NutsSession;
import net.vpc.app.nuts.NutsUpdateUserCommand;
import net.vpc.app.nuts.NutsUserConfig;
import net.vpc.app.nuts.NutsWorkspace;
import net.vpc.app.nuts.core.spi.NutsRepositoryConfigManagerExt;
Expand All @@ -48,84 +50,23 @@
* @author vpc
* @since 0.5.4
*/
public class DefaultNutsAddUserCommand implements NutsAddUserCommand {
public class DefaultNutsAddUserCommand extends NutsWorkspaceCommandBase<NutsAddUserCommand> implements NutsAddUserCommand {

private boolean trace = true;
private boolean force = false;
private String login;
private String remoteIdentity;
private String password;
private Set<String> rights = new HashSet<String>();
private Set<String> groups = new HashSet<String>();
private NutsSession session;
private final Set<String> rights = new HashSet<>();
private final Set<String> groups = new HashSet<>();
private NutsRepository repo;
private NutsWorkspace ws;

public DefaultNutsAddUserCommand(NutsWorkspace ws) {
this.ws = ws;
super(ws);
}
public DefaultNutsAddUserCommand(NutsRepository repo) {
super(repo.getWorkspace());
this.repo = repo;
}

@Override
public boolean isTrace() {
return trace;
}

@Override
public DefaultNutsAddUserCommand trace() {
return trace(true);
}

@Override
public DefaultNutsAddUserCommand trace(boolean trace) {
return setTrace(trace);
}

@Override
public DefaultNutsAddUserCommand setTrace(boolean trace) {
this.trace = trace;
return this;
}

@Override
public boolean isForce() {
return force;
}

@Override
public DefaultNutsAddUserCommand force() {
return force(true);
}

@Override
public DefaultNutsAddUserCommand force(boolean force) {
return setForce(force);
}

@Override
public DefaultNutsAddUserCommand setForce(boolean force) {
this.force = force;
return this;
}

@Override
public NutsSession getSession() {
return session;
}

@Override
public DefaultNutsAddUserCommand session(NutsSession session) {
return setSession(session);
}

@Override
public DefaultNutsAddUserCommand setSession(NutsSession session) {
this.session = session;
return this;
}

@Override
public String getLogin() {
return login;
Expand Down Expand Up @@ -328,4 +269,24 @@ public NutsAddUserCommand run() {
}
return this;
}

public NutsAddUserCommand parseOptions(String... args) {
NutsCommandLine cmd = new NutsCommandLine(args);
NutsCommandArg a;
while ((a = cmd.next()) != null) {
switch (a.strKey()) {
default: {
if (!super.parseOption(a, cmd)) {
if (a.isOption()) {
throw new NutsIllegalArgumentException("Unsupported option " + a);
} else {
//id(a.getString());
}
}
}
}
}
return this;
}

}
Loading

0 comments on commit 8056945

Please sign in to comment.