``` {r, eval=FALSE}
create_repo("~/Desktop/myproject")
download_repo("url")
 2. Make some changes: work on your project as normal. Don't forget to save your changes. [insert picture/code here] 3. Review and visualise the changes you have made to your project. [insert picture here] ```r changes()
``` {r eval=FALSE}
record("a message to your future self")
## Fixing stuff, moving back, recording stuff 5. Look at your history of records ```r # print a history of your past records in your console: timeline()
# Made a mistake? Return your project to your last record: scrub() # ...or to another previous record of your choice: retrieve(1) # take a peek into any older record go_to(2)
# Synchronize your work with a new or existing remote repository sync("url") # (not yet implemented)
# load the package library(changes) # make a new repository in your working directory # (you only need to do this the first time you work with the project) create_repo("~/Desktop/myproject") # tell the repository if there are files (e.g. large data output files) you # don't want to keep copies of ignore("output/results.csv") # (you can always change your mind) unignore("output/results.csv") # work on your project as normal, and save your changes cat("this is fun!\n", file = "README.md", append = TRUE) # see which files have changed changes() # record the changes you have made record("added stuff to readme") # you can keep working on and adding files in this folder, and recording your # changes regularly with record() # If you make a change you don't want to keep, you can undo them and go back to # your last record with scrub() cat("I could do this all day.\n", file = "README.md", append = TRUE) changes() scrub() changes() # you can look at your history of records... timeline() # ... and go back in time to recover the project at any one of your records go_to(2) # all of the files will have been changed back to how they were at record 2 timeline() # we can always go back to the future go_to(3) # if you want to start again from a previous record, you can do retrieve() to # bring that record to the end of your timeline retrieve(2) # all the work you recorded since then will still be stored, in case you need it # later
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.