Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
trixi-framework
GitHub Repository: trixi-framework/Trixi.jl
Path: blob/main/docs/literate/src/files/first_steps/changing_trixi.jl
5593 views
1
#src # Changing Trixi.jl itself
2
3
# If you plan on editing Trixi.jl itself, you can download Trixi.jl locally and run it from
4
# the cloned directory.
5
6
7
# ## Forking Trixi.jl
8
9
# To create your own fork of Trixi.jl, log in to your GitHub account, visit the
10
# [Trixi.jl GitHub repository](https://github.com/trixi-framework/Trixi.jl) and click the `Fork`
11
# button located in the upper-right corner of the page. Then, click on `Create fork` in the opened
12
# window to complete the forking process.
13
14
15
# ## Cloning Trixi.jl
16
17
18
# ### Windows
19
20
# If you are using Windows, you can clone Trixi.jl by using the GitHub Desktop tool:
21
# - If you do not have a GitHub account yet, create it on
22
# the [GitHub website](https://github.com/join).
23
# - Download and install [GitHub Desktop](https://desktop.github.com/) and then log in to
24
# your account.
25
# - Open GitHub Desktop, press `Ctrl+Shift+O`.
26
# - In the opened window, navigate to the `URL` tab and paste `trixi-framework/Trixi.jl` or
27
# `YourGitHubUserName/Trixi.jl` to clone your own fork of Trixi.jl, and choose the
28
# path to the folder where you want to save Trixi.jl. Then click `Clone` and Trixi.jl will be
29
# cloned to your computer.
30
31
# Now you cloned Trixi.jl and only need to tell Julia to use the local clone as the package sources:
32
# - Open a terminal using `Win+r` and `cmd`. Navigate to the folder with the cloned Trixi.jl using `cd`.
33
# - Create a new directory `run`, enter it, and start Julia with the `--project=.` flag:
34
# ```shell
35
# mkdir run
36
# cd run
37
# julia --project=.
38
# ```
39
# - Now run the following commands to install all relevant packages:
40
# ````julia
41
# using Pkg; Pkg.develop(PackageSpec(path="..")) # Tell Julia to use the local Trixi.jl clone
42
# Pkg.add(["OrdinaryDiffEqLowStorageRK", "OrdinaryDiffEqSSPRK", "Plots"]) # Install additional packages
43
# ````
44
45
# Now you already installed Trixi.jl from your local clone. Note that if you installed Trixi.jl
46
# this way, you always have to start Julia with the `--project` flag set to your `run` directory,
47
# e.g.,
48
# ```shell
49
# julia --project=.
50
# ```
51
# if already inside the `run` directory.
52
53
54
# ### Linux
55
56
# You can clone Trixi.jl to your computer by executing the following commands:
57
# ```shell
58
# git clone [email protected]:trixi-framework/Trixi.jl.git
59
# # If an error occurs, try the following:
60
# # git clone https://github.com/trixi-framework/Trixi.jl
61
# cd Trixi.jl
62
# mkdir run
63
# cd run
64
# julia --project=. -e 'using Pkg; Pkg.develop(PackageSpec(path=".."))' # Tell Julia to use the local Trixi.jl clone
65
# julia --project=. -e 'using Pkg; Pkg.add(["OrdinaryDiffEqLowStorageRK", "OrdinaryDiffEqSSPRK", "Plots"])' # Install additional packages
66
# ```
67
# Alternatively, you can clone your own fork of Trixi.jl by replacing the link
68
# `[email protected]:trixi-framework/Trixi.jl.git` with `[email protected]:YourGitHubUserName/Trixi.jl.git`.
69
70
# Note that if you installed Trixi.jl this way,
71
# you always have to start Julia with the `--project` flag set to your `run` directory, e.g.,
72
# ```shell
73
# julia --project=.
74
# ```
75
# if already inside the `run` directory.
76
77
78
# ## Developing Trixi.jl
79
80
# If you've created and cloned your own fork of Trixi.jl, you can make local changes to Trixi.jl
81
# and propose them as a Pull Request (PR) to be merged into `trixi-framework/Trixi.jl`.
82
83
# Linux and MacOS utilize the `git` version control system to manage changes between your local and
84
# remote repositories. The most commonly used commands include `add`, `commit`, `push` and `pull`.
85
# You can find detailed information about these functions in the
86
# [Git documentation](https://git-scm.com/docs).
87
88
# For Windows and GitHub Desktop users, refer to the
89
# [documentation of GitHub Desktop](https://docs.github.com/en/desktop/overview/getting-started-with-github-desktop#making-changes-in-a-branch).
90
91
# After making local changes to Trixi.jl and pushing them to the remote repository, you can open a
92
# Pull Request (PR) from your branch to the main branch of `trixi-framework/Trixi.jl`. Then, follow
93
# the Review checklist provided in the Pull Request to streamline the review process.
94
95
96
# ## Additional reading
97
98
# To further delve into Trixi.jl, you may have a look at the following introductory tutorials.
99
# - [Behind the scenes of a simulation setup](@ref behind_the_scenes_simulation_setup) will guide
100
# you through a simple Trixi.jl setup ("elixir"), giving an overview of what happens in the
101
# background during the initialization of a simulation. It clarifies some of the more
102
# fundamental, technical concepts that are applicable to a variety of (also more complex)
103
# configurations.
104
# - [Introduction to DG methods](@ref scalar_linear_advection_1d) will teach you how to set up a
105
# simple way to approximate the solution of a hyperbolic partial differential equation. It will
106
# be especially useful to learn about the
107
# [Discontinuous Galerkin method](https://en.wikipedia.org/wiki/Discontinuous_Galerkin_method)
108
# and the way it is implemented in Trixi.jl.
109
# - [Adding a new scalar conservation law](@ref adding_new_scalar_equations) and
110
# [Adding a non-conservative equation](@ref adding_nonconservative_equation)
111
# describe how to add new physics models that are not yet included in Trixi.jl.
112
# - [Callbacks](@ref callbacks-id) gives an overview of how to regularly execute specific actions
113
# during a simulation, e.g., to store the solution or adapt the mesh.
114
115