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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added installation instructions for new pkg mode in README #20

Merged
merged 4 commits into from
Sep 16, 2018
Merged
Changes from 1 commit
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
64 changes: 29 additions & 35 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,32 +11,41 @@
# PeriodicTable.jl
A very simple package for accessing elements in the Periodic Table! :fire:

## Installation
### Installation
Since PeriodicTable is registered in `METADATA.jl`, you can directly install it like,
```julia
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the future we might have to replace METADATA.jl by the general registry on https://github.com/JuliaRegistries/General.

# for julia version <= 0.6
julia> using Pkg
julia> Pkg.add("PeriodicTable")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add using Pkg here.

Copy link
Member Author

@rahulkp220 rahulkp220 Sep 16, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would this seem better? Later when we drop support for version 0.6, we will have this part removed.

# for version <= 0.6
julia> using Pkg
julia> Pkg.add("PeriodicTable")

# for version >= 0.7
julia>] # switch to pkg> mode
(v1.0) pkg> add PeriodicTable

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, the upper one won't work on 0.6 (there exists no module Pkg on 0.6). As I said, I'd just drop the # for version ... comments and only give instructions for 0.7+.

If you would really want to indicate both ways (0.6 and 0.7+) then I'd switch the order (0.7+ first) and remove the using Pkg.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I missed that part.


# OR
julia>] # switch to pkg> mode
# for julia version >= 0.7
julia>]
(v1.0) pkg> add PeriodicTable
```

## Update
```julia
julia> Pkg.update("PeriodicTable")

# OR
julia>] # switch to pkg> mode
(v1.0) pkg> update PeriodicTable
```

## How it works?
### How it works?
PeriodicTable.jl provides a Julia interface to a small database of element
properties for all of the elements in the periodic table. In particular
properties for all of the elements in the periodic table.

```julia
using PeriodicTable
julia> using PeriodicTable

julia> elements
Elements(…119 elements…):
H He
Li Be B C N O F Ne
Na Mg Al Si P S Cl Ar
K Ca Sc Ti V Cr Mn Fe Co Ni Cu Zn Ga Ge As Se Br Kr
Rb Sr Y Zr Nb Mo Tc Ru Rh Pd Ag Cd In Sn Sb Te I Xe
Cs Ba Hf Ta W Re Os Ir Pt Au Hg Tl Pb Bi Po At Rn
Fr Ra Rf Db Sg Bh Hs Mt Ds Rg Cn Nh Fl Mc Lv Ts Og
Uue
La Ce Pr Nd Pm Sm Eu Gd Tb Dy Ho Er Tm Yb Lu
Ac Th Pa U Np Pu Am Cm Bk Cf Es Fm Md No Lr
```
exports a global variable called `elements`, which is a collection of

In particular `PeriodicTable` exports a global variable called `elements`, which is a collection of
`Element` data structures. You can look up elements by name (case-insensitive)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd move the first sentence, "In particular PeriodicTable exports a global variable called elements, which is a collection of Element data structures. ", before the PT visualization.

via `elements["oxygen"]`, by symbol via `elements[:O]`, or by number via
`elements[8]`, for example.
Expand Down Expand Up @@ -75,30 +84,15 @@ julia> elements[1:4]
Element(Beryllium)
```

### View the Periodic Table!
```julia
julia> elements
Elements(…119 elements…):
H He
Li Be B C N O F Ne
Na Mg Al Si P S Cl Ar
K Ca Sc Ti V Cr Mn Fe Co Ni Cu Zn Ga Ge As Se Br Kr
Rb Sr Y Zr Nb Mo Tc Ru Rh Pd Ag Cd In Sn Sb Te I Xe
Cs Ba Hf Ta W Re Os Ir Pt Au Hg Tl Pb Bi Po At Rn
Fr Ra Rf Db Sg Bh Hs Mt Ds Rg Cn Nh Fl Mc Lv Ts Og
Uue
La Ce Pr Nd Pm Sm Eu Gd Tb Dy Ho Er Tm Yb Lu
Ac Th Pa U Np Pu Am Cm Bk Cf Es Fm Md No Lr
```

## Data by
* [Periodic-Table-JSON](https://github.com/Bowserinator/Periodic-Table-JSON)
### Data by
The data used for this package has been pulled up in parts from [here](https://github.com/Bowserinator/Periodic-Table-JSON)
Some information has been (and will be) added over the period of time.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Some information has been (and will be) added over time." sounds better to me.

Also there seems to be a dot missing after the here link.


## Developed together with
### Developed together with
* [Steven G. Johnson](https://github.com/stevengj)
* [Jacob Wikmark](https://github.com/lancebeet)
* [Carsten Bauer](https://github.com/crstnbr)

## Facing issues? :scream:
### Facing issues? :scream:
* Open a PR with the detailed expaination of the issue
* Reach me out [here](https://www.rahullakhanpal.in)