Add 'wiki/docs/Installation.md'

This commit is contained in:
Jeison Yehuda Amihud (Blender Dumbass) 2021-03-03 20:28:38 +00:00
parent c2be1d1e9b
commit 2078c60e40

106
wiki/docs/Installation.md Normal file
View file

@ -0,0 +1,106 @@
**NOTE:** *This Documentation Article is written for a specific verion of VCStudio mentioned in the title. If you have a newer version, some things might be changed. There could be a newer version of this article in the [wiki.](https://notabug.org/jyamihud/VCStudio/wiki/_pages) If there is non. Please be aware of possible changes. The Version could be found in the bottom, right corner of VCStudio*
**COPYLEFT:** *This article is a part of* **VCStudio** *and might be used and reproduced using either* **GNU General Public License** *or* **CC-BY-SA**.
# Installation
### Content:
- Video Tutorial
- Simple guide
- Advanced explanation
# Video Tutorial
[![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/promotions/thumb_lbry_link.png)](https://open.lbry.com/@blender-organizer:5/rnd0001-4061:1?r=7YADjAZEbHJg8n4qV5rAuBh5Hca7cZQK)
![](https://notabug.org/jyamihud/VCStudio/raw/master/settings/themes/OldSchool/icons/lbry.png) *Click on the image to view in LBRY* or ![](https://notabug.org/jyamihud/VCStudio/raw/master/settings/themes/OldSchool/icons/video.png) [Download Video](https://cdn.lbryplayer.xyz/api/v4/streams/free/rnd0001-4061/1f56bef7a754d6be38ea78d5ef0b6bb17952f517/ffd973)
# Simple Guide
To understand how to install VCStudio you need to understand a concept of scripts vs compiled software. Most software. Either the Linux kernel or Blender are compiled. The source code is read by a special program called a compiler and this program returns a binary file with direct instructions to the CPU. More often then not when installing software from the source code, from websites like NotABug or GitHub, you will need to run a special script that will do all the compilation and configuration for you.
On the other hand you have scripts. Which are run in a program called an interpriter. Python is one such program. And the source code of VCStudio writen so to run in a Python 3 interpriter.
### Need to install:
We need to have a few things installed before we can run VCStudio:
- **GNU / Linux**. VCStudio was built for GNU / Linux operating system. Which is a Free Software alternative to programs like Microsoft Windows or Apple's OS. What ever the name is. While you can technically make it run on any operating system, some unintentional bugs will accure since nothing other then GNU / Linux was tested when writing VCStudio. So I highly advice to use GNU / Linux for this.
If you are new to GNU / Linux you can try various [popular destributions.](https://distrowatch.com/dwres.php?resource=major) And if you want to use only [Free Software](https://www.fsf.org/) please look at the [GNU certified destributions.](https://www.gnu.org/distros/free-distros.html)
- **Python 3**. As I mentioned earlier we need an interpriter. And the code is written to work with Python 3. Most GNU / Linux Destributions will have it pre-installed. You can see the version of the python installed by launching the terminal and typing `python3` into it. If it's not there. Please install it.
![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/43.png)
- **Py-GTK**. For python 3 there should be installed a whole suit of GTK Graphical Toolkit modules. Without them the program will fail to draw a window. To test that they are installed you can type `from gi.repository import Gtk` to the python console.
![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/44.png)
A warning such as `<stdin>:1: PyGIWarning:` is okay. As long it does not say something like `ModuleNotFoundError: No module named 'Gtk'`
### Get a copy of VCStudio
You can get a copy of VCStudio in a ZIP format [here.](https://notabug.org/jyamihud/VCStudio/archive/master.zip) or by using `git` in terminal. Be aware, not all systems come with git by default.
`git clone https://notabug.org/jyamihud/VCStudio`
### Get into the folder with terminal
The first launch of VCStudio will be a kind of installation run. So we need to do it from the terminal. For this unpack the ZIP and `cd` into the folder. *In case you got a copy using git simply use* `cd VCStudio`. In most modern file managers on GNU / Linux you will have an option to open a folder in terminal when clicking on the folder with right mouse button.
### First run
Now you can run VCStudio. Type into the terminal `python3 run.py` and hit Enter. You will see a window like this one.
![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/45.png)
Just type in the language you are most confortable with from the list. And press enter. It will launch a thing called troubleshooter. It will check all the scripts and give you information if something is currently wrong with the your copy. If you see anything failed please [report to us.](https://notabug.org/jyamihud/VCStudio/issues)
Now just repeat the last command `python3 run.py` and if everything is okay you will launch the UI of the progect manager.
![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/46.png)
On some systems it will also create an entry of the menu. So you will not need to launch a terminal every time you want to use VCStudio.
![](https://notabug.org/jyamihud/update_manager/raw/master/vcstudio/47.png)
**Congradulations!**
# Advanced explanation
*The folowing part of the article is for hard core nerdy people who want to know how everything works. And contains redundant information for a simple person that just want to use VCStudio. Anyway here it is.*
### Files
The best documentation is to read the code of the software directly. Here are the parts of VCStudio that are responsible for the disaster that is installation.
- [run.py](https://notabug.org/jyamihud/VCStudio/src/master/run.py) Main file that operates the rest of the guts.
- [troubleshooter/troubleshooter.py](https://notabug.org/jyamihud/VCStudio/src/master/troubleshooter/troubleshooter.py) The file responsible for most of the checking and configuration process.
- [settings/settings.py](https://notabug.org/jyamihud/VCStudio/src/master/settings/settings.py) File handling settings.
- [settings/talk.py](https://notabug.org/jyamihud/VCStudio/src/master/settings/talk.py) File handling languages.
- [settings/update.data](https://notabug.org/jyamihud/VCStudio/src/master/settings/update.data) File with update information. But in this case a file that holds a list of all files in the VCStudio program.
**So what is happening when you run the run.py?**
Well at first. VCStudio is unsure of what language to use for the rest of the checking procedure. I would use English for the whole process. But I made myself use multi-language support as early as possible. And as weird as it might sound, some people just don't speak English.
**How do we know that there is no language yet set up?**
Basically on every startup it tries to make a system notification. Something like `:) I'm Happy To See You` which is reading the [language packs](https://notabug.org/jyamihud/VCStudio/src/master/settings/languages) using [talk.text()](https://notabug.org/jyamihud/VCStudio/src/master/settings/talk.py) function. Of course if in the settings file there is no setting for Language it will fail. And so if any fail accurs the [troubleshooter](https://notabug.org/jyamihud/VCStudio/src/master/troubleshooter/troubleshooter.py) is called.
**What the troubleshooter does?**
Troubleshooter is a script to check / fix problems. Tho at the moment [fix.py](https://notabug.org/jyamihud/VCStudio/src/master/troubleshooter/fix.py) is empty of any functionality since there was no mistakes horrible enough found that troubleshooter should fix. This is why please [report your problems](https://notabug.org/jyamihud/VCStudio/issues).
We can break the troubleshooter activity into 4 parts.
- **Language**. Checking if there is any language in a settings and if not give user a little interface to choose a language.
- **Check Python**. Basically checking the installed modules like Gtk, Cairo, PIL and so on.
- **Check VCStudio**. Checking all the files listed in [update.data](https://notabug.org/jyamihud/VCStudio/src/master/settings/update.data) that they exists and working. At this stage some files might fail without actually making too much problems. But these are fixes to make.
- **Make Desktop Entry**. If you read the first part of this documentation carefully. VCStudio adds it self into a system application menu. It does it using what's called a [Desktop Entry](https://freedesktop.org/wiki/Specifications/desktop-entry-spec/) that most GNU / Linux application launchers understand.
**How is it launching the VCStudo it self the second time?**
Well the second time the [talk.text()](https://notabug.org/jyamihud/VCStudio/src/master/settings/talk.py) function does not fail. So it's just continuing with the rest of the UI scripts. Mainy the [project_manager/pm_gtk.py](https://notabug.org/jyamihud/VCStudio/src/master/project_manager/pm_gtk.py).