From your own fork, you can add stimuli right in GitHub like this:
-
Click on the appropriate directory. For images, that's
img. For audio and video files, the appropriate directory depends on their file format. For instance, mp4 files go in themp4directory. -
Click 'Upload files.' Drag and drop the files from your computer that you want to put online.
-
Click 'Commit changes,' adding a brief message explaining what you added or changed for posterity.
By keeping the various file types in their own directories, and using the same filenames for equivalent files (like an mp4 and webm version of the same video), you will be ready to make use
That's most straightforward to do using the command line or a desktop client for GitHub, like GitHub Desktop or Sourcetree. However, you can also do it right in Github by clicking 'Create new file' instead of 'Upload files' from the place where you want to add a new directory. Then, in the box to type the file name, type NewDirectoryName/README.md, replacing NewDirectoryName with your desired directory name. This will create the new directory and a README.md file inside it. Then you can add other files too.
If you always want to point to the latest version of your stimuli, you can access those at
https://raw.githubusercontent.com/YOUR_USERNAME/lookit-stimuli-template/master/DIRECTORY/FILENAME.EXT
For instance, if your GitHub username is Isaaq-Khader, and you have a purple-condition.mp4 file in the mp4 directory, you could link to it at
https://raw.githubusercontent.com/Isaaq-Khader/EASTLab-LookIt/master/mp4/purple-condition.mp4
Most Lookit frames allow you to specify a baseDir or base directory for your files, and then only provide filenames instead of full paths. You can learn more about that in the docs. In this case, your baseDir would be:
https://raw.githubusercontent.com/YOUR_USERNAME/EASTLab-LookIt/master/
This option has the advantage that if you make slight adjustments to your stimuli, you don't also have to update your study to use the new versions. However, if you delete any files or make other unexpected changes, it may break something in your study.
If you want to point to a specific, fixed version of your stimuli - a 'snapshot in time' - you can select a particular "commit" to point to. From your fork of this repository, click the "N commits" at the top to view a list of commits. Click the "clipboard" icon next to the commit you want to use. This copies the COMMIT_ID.
The URLs for the stimuli as they were at the time of this commit are:
https://raw.githubusercontent.com/YOUR_USERNAME/EASTLab-LookIt/COMMIT_ID/DIRECTORY/FILENAME.EXT
And the baseDir to use is:
https://raw.githubusercontent.com/YOUR_USERNAME/EASTLab-LookIt/COMMIT_ID/
Deleting files: You can delete individual files by navigating to them in GitHub and then clicking the "trash" icon. You'll be prompted to commit this change.
Changing files: You can upload new versions of your files in the same directory where the old ones are to replace them.
Each time you delete a file or upload a new file, you will need to commit the change and can write a short message about what you changed and why. Your commit history then shows a complete record of the changes you've made over time, which is very helpful for your future self.