Setup.jl/README.org

86 lines
2.2 KiB
Org Mode
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#+title: Setup.jl
#+author: TEC
This is my personal Julia configuration. It has grown far beyond my wildest imagination.
* Installation
#+begin_src shell
julia --startup-file=no -e 'using Pkg; Pkg.add(url="https://git.tecosaur.net/tec/Setup.jl.git"); using Setup; Setup.install()'
#+end_src
* Features
** Autoloading
Instead of loading packages whose functionality might be needed at some point,
load them on-demand. Lazy loading for the win!
The following packages are currently supported:
+ The standard library (=Base64=, =CRC32c=, =Dates=, =Distributions=, =Downloads=,
=LinearAlgebra=, =Markdown=, =Mmap=, =Pkg=, =Printf=, =REPL=, =Random=, =SHA=, =Serialisation=,
=Statistics=, =StatsBase=, =TOML=, =Tar=, =Test=, =Threads=, =UUIDs=)
+ =BaseDirs=
+ =BenchmarkTools=
+ =CSV=
+ =Cthulhu=
+ =DataFrames=
+ =DataToolkit=
+ =Debugger=
+ =Distributions=
+ =JET=
+ =JSON3=
+ =Org=
+ =WhyNotEqual=
** Function/Structure inspection
Get a sense of a function or structure with the =about= function/macro.
** Environment tweaks
*** Shorter activation
Add =a= as a shorthand for =activate=
*** Easier temp environments
Add =-t= as a shorthand for =--temp=, with the activate change this means opening a
temporary environment is now a bit quicker:
#+begin_example
pkg> a -t
#+end_example
instead of
#+begin_example
pkg> activate --temp
#+end_example
*** Environment stack
Load and unload named environments with the new =pkg> (un)stack= set of commands.
** Command puns
For more easily running ~Cmd~s, we now have the following syntactic puns.
#+begin_src julia
~ `cmd` # read to string
! `cmd` # print output
!~ `cmd` # read and print output
`a` | `b` # pipe commands
#+end_src
** Package configuration
Thanks to package extensions, it's fairly straightforward to bundle per-package
customisation code. Currently this covers the following:
+ Setting the Makie theme based on the terminal colours when loading =CairoMakie=
+ Pushing the =Gadfly= display
+ Changing the =HDF5= icons
+ Loading =ImageShow= when =JpegTurbo=, =Netpbm=, =PNGFiles=, =QOI=, or =TiffImages= are loaded
+ Load an appropriate =OhMyREPL= theme on startup
+ Add pretty colour show methods for =Color= types