Skip to content
This repository was archived by the owner on Mar 4, 2024. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ disable=import-star-module-level,old-octal-literal,oct-method,print-statement,un
# Set the output format. Available formats are text, parseable, colorized, msvs
# (visual studio) and html. You can also give a reporter class, eg
# mypackage.mymodule.MyReporterClass.
output-format=text
output-format=colorized

# Put messages in a separate file for each module / package specified on the
# command line instead of printing them on stdout. Reports (if any) will be
Expand Down Expand Up @@ -231,7 +231,7 @@ notes=FIXME,XXX,TODO
[SIMILARITIES]

# Minimum lines number of a similarity.
min-similarity-lines=4
min-similarity-lines=10

# Ignore comments when computing similarities.
ignore-comments=yes
Expand Down Expand Up @@ -320,14 +320,14 @@ exclude-protected=_asdict,_fields,_replace,_source,_make
[DESIGN]

# Maximum number of arguments for function / method
max-args=5
max-args=10

# Argument names that match this expression will be ignored. Default to name
# with leading underscore
ignored-argument-names=_.*

# Maximum number of locals for function / method body
max-locals=15
max-locals=20

# Maximum number of return / yield for function / method body
max-returns=6
Expand Down
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ language: python
python:
- "2.7"
install: "pip install -r dev-requirements.pip"
script: py.test tests
script: pylint lecli && py.test tests
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ The user and account management functionality of the CLI can only be used with a
It is worth noting that if your account does not have a specific owner set then some user management functions may fail with a 500 error; to check if an owner is set the 'getowner' command below can be used. If no owner is set then you must regenerate the owner API key, at which point you will be asked to set an account owner.

####List Users
The 'userlist' command will return a list of all users that have access to the account for which the CLI has been configured. The command will return the users first and last name, email address, user ID and the last time they logged in. The 'userlist' command does not accept any arguments.
The 'userlist' command will return a list of all users that have access to the account for which the CLI has been configured. The command will return the users first and last name, email address, user key and the last time they logged in. The 'userlist' command does not accept any arguments.

Example usage:
```
Expand All @@ -148,14 +148,14 @@ lecli userlist
The 'useradd' command allows you to add a user to your account. There are two ways to add users, depending on whether they are a new or existing user.
A new user is a user that has no Logentries account.

To add a new user you must provide their first and last name, and email address. If successfully added the CLI will print the users account information, including their newly generated user Id. A user added via the CLI must then go to https://logentries.com/user/password-reset/ and enter their email address. They will then be sent a link that they can use to setup the password for their new account.
To add a new user you must provide their first and last name, and email address. If successfully added the CLI will print the users account information, including their newly generated user key. A user added via the CLI must then go to https://logentries.com/user/password-reset/ and enter their email address. They will then be sent a link that they can use to setup the password for their new account.

A new user can be added using the following command
```
lecli useradd -f John -l Smith -e john.smith@email.com
```

To add an existing user (i.e. a user that already has a Logentries account, even if not associated with your account), you must first obtain their user Id. The user can obtain their user Id from the account management page of the Logentries application at https://logentries.com
To add an existing user (i.e. a user that already has a Logentries account, even if not associated with your account), you must first obtain their user key. The user can obtain their user key from the account management page of the Logentries application at https://logentries.com

An existing user can be added to your account use the following command
```
Expand Down Expand Up @@ -210,9 +210,9 @@ Rename a team with the given UUID to given name.
####Add User to a Team
Add a new user to a team with the given UUID and user UUID respectively.

lecli addusertoteam <team id> <user id>
lecli addusertoteam <team id> <user key>

####Delete User from a Team
Add a new user to a team with the given UUID and user UUID respectively.

lecli deleteuserfromteam <team id> <user id>
lecli deleteuserfromteam <team id> <user key>
3 changes: 2 additions & 1 deletion dev-requirements.pip
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ requests==2.9.1
pytz==2016.4
termcolor==1.1.0
tabulate==0.7.5
appdirs==1.4.0
appdirs==1.4.0
pylint==1.6.4
4 changes: 4 additions & 0 deletions lecli/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
"""
lecli __init__.py
"""

from lecli._version import __version__
__author__ = 'Logentries by Rapid7'
5 changes: 4 additions & 1 deletion lecli/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
__version__ = '0.3.2'
"""
Version module. We should change the version here when we need to.
"""
__version__ = '0.4.0'
Loading