<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Akbar Tukhtamurotov on Medium]]></title>
        <description><![CDATA[Stories by Akbar Tukhtamurotov on Medium]]></description>
        <link>https://medium.com/@akbartukhtamurotov?source=rss-959e1ef081af------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*29TMq5-orom21TBFknIgSg.jpeg</url>
            <title>Stories by Akbar Tukhtamurotov on Medium</title>
            <link>https://medium.com/@akbartukhtamurotov?source=rss-959e1ef081af------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 29 Nov 2026 12:56:48 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@akbartukhtamurotov/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to disable iTerm window automatic minimizing]]></title>
            <link>https://medium.com/@akbartukhtamurotov/how-to-disable-iterm-window-automatic-minimizing-847f949a433e?source=rss-959e1ef081af------2</link>
            <guid isPermaLink="false">https://medium.com/p/847f949a433e</guid>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[command-line]]></category>
            <category><![CDATA[iterm2]]></category>
            <category><![CDATA[macos]]></category>
            <category><![CDATA[apple]]></category>
            <dc:creator><![CDATA[Akbar Tukhtamurotov]]></dc:creator>
            <pubDate>Wed, 01 Mar 2023 15:14:10 GMT</pubDate>
            <atom:updated>2023-03-01T15:14:10.431Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mhwS-qGAj0XWdxtbYL1h2w.png" /></figure><p>If you use iTerm often, you might know that your window might be minimized automatically so it won’t reappear when you press <strong>command(</strong>⌘<strong>) + tab. </strong>To fix this do the following steps:</p><p>1. Go to <strong>Settings -&gt; Profiles</strong> tab and click on</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pPRWnNoe4ibksOmG_YGhOg.png" /></figure><p>2. Click on <strong>Keys</strong> tab on the left and then <strong>Configure Hotkey Window. </strong>Following window will appear after you click on Configure Hotkey Window. Then enable <strong>Automatically reopen on app reactivation</strong> checkbox.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SaG7BR9bI-IrOpbXa_NQwQ.png" /></figure><p>That’s it, you can test it out now 🙂</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=847f949a433e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Command-line Launcher in JetBrains]]></title>
            <link>https://medium.com/@akbartukhtamurotov/command-line-launcher-jetbrains-toolbox-and-ides-89fc9733dc68?source=rss-959e1ef081af------2</link>
            <guid isPermaLink="false">https://medium.com/p/89fc9733dc68</guid>
            <category><![CDATA[jetbrains]]></category>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[command-line]]></category>
            <category><![CDATA[productivity]]></category>
            <dc:creator><![CDATA[Akbar Tukhtamurotov]]></dc:creator>
            <pubDate>Tue, 26 Apr 2022 07:52:24 GMT</pubDate>
            <atom:updated>2022-05-23T06:28:40.918Z</atom:updated>
            <content:encoded><![CDATA[<h3>Visual Studio Code</h3><p>Let’s say you want to open your projects from your terminal using your favorite IDE or editor straightaway. If you use Visual Studio Code as your editor, you can already use code {your project directory} terminal command to open your project quickly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mfI2f7PyrtH7Xi6MlVWDOQ.png" /></figure><p>This will open the project in Visual Studio Code</p><h3>Jetbrains IDE</h3><p>But what about Jetbrains projects? There is no command-line launcher command by default. You need to enable it.</p><p>If you installed your IDE manually by downloading from the JetBrains webpage, you will do this withCreate Command-line Launcher... option in Tools menu. When you click that, it will prompt you to enter the location within $PATH . $PATHis an environmental variable in the operating system that tells the shell which directories to search for executable files (i.e., ready-to-run programs) in response to commands issued by a user. You can see the contents of $PATH by typing echo $PATH command in your terminal.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9iKpueE4WiVXXYSWoTsQKA.png" /></figure><p>You can choose one of these directories you have in your $PATH (that is suitable to store your scripts). You can add any location of your choice to your `$PATH` and then use that directory as your location for the command-line launcher command to reside.</p><h3>Jetbrains Toolbox</h3><p>However, if you installed your Jetbrains IDE with Jetbrains Toolbox you can’t create your launcher from inside your IDE.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/972/1*eK0XFSG_lcyJRh5MpvdA4A.png" /></figure><p>That means you need to create a launcher inside Toolbox . So go to Toolbox and click Settings</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/896/1*-9q6n-uOg7yxD29Mpgvvpw.png" /></figure><p>Under Tools section click on Generate shell script</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LJIPI27ciT38IwXi6-OHwA.png" /></figure><p>Then enter any location within $PATH variable inside the input form.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*JLEJ2Qykjv-tShzLKKrTnA.png" /></figure><p>Then click Apply . This will generate launcher commands for every installed project with Toolbox</p><p>For this example, I typed /opt/homebrew/bin folder which is brew folder for executables. Now I can see which launcher commands were created. I have installed IntelliJ Idea and Webstorm . So now idea and webstorm commands are available for me to use in the terminal. And I can now open my projects with idea {my project location} or webstorm {my project location}</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ghw3tp2-1pE1eFdizJNIyw.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=89fc9733dc68" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to deploy a Laravel application with GitLab CI/CD]]></title>
            <link>https://medium.com/@akbartukhtamurotov/how-to-deploy-a-laravel-application-with-gitlab-ci-cd-b6de8aa6a611?source=rss-959e1ef081af------2</link>
            <guid isPermaLink="false">https://medium.com/p/b6de8aa6a611</guid>
            <category><![CDATA[gitlab-runner]]></category>
            <category><![CDATA[laravel]]></category>
            <category><![CDATA[gitlab-ci]]></category>
            <category><![CDATA[gitlab]]></category>
            <dc:creator><![CDATA[Akbar Tukhtamurotov]]></dc:creator>
            <pubDate>Tue, 16 Apr 2019 10:49:39 GMT</pubDate>
            <atom:updated>2019-04-18T13:41:32.411Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iqx2WN3eo0ktnd2m1M3StQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/photos/C8VWyZhcIIU?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Joseph Chan</a> on <a href="https://unsplash.com/search/photos/star-wars-droid?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>When I want to deploy my last changes to my VPS, I always connect to my server with ssh and pull the project, install last packages, run migrations, and so on. I’m a lazy person to repeat this process over and over. Auto deployment comes to rescue. So whenever I make changes and push it, I want my project to be up and running with the last changes there too. I have so many options to accomplish this task including Jenkins, TeamCity, CircleCi and others. But my project hosted in GitLab and I have not so many space to install hundreds of megabytes of tools in my VPS.</p><p>We will setup on Ubuntu 16.04. Steps we should finish are:</p><ol><li>Create <strong>deployer</strong> user</li><li>Install gitlab runner</li><li>Register new gitlab runner</li><li>Create <strong>.gitlab-ci.yml </strong>file</li></ol><p><strong>Create deployer user</strong></p><ul><li>Firs of all, ssh into your remote server:</li></ul><pre>ssh root@your_ip_address</pre><ul><li>Create new user</li></ul><pre><strong>sudo adduser deployer</strong>      # Fill in user info and password<br><strong>sudo usermod -g www-data deployer</strong> # Assign group www-data(primary)</pre><p>After this you login to this user in order to create ssh keys.</p><pre>ssh deployer@your_ip_address</pre><p>After successfull login, generate ssh keys and copy path to <strong>private key</strong>. If you need more information, check this article <a href="https://www.digitalocean.com/community/tutorials/how-to-set-up-ssh-keys--2">https://www.digitalocean.com/community/tutorials/how-to-set-up-ssh-keys--2</a> In our case it may be something like this:</p><pre><strong>ssh-keygen</strong><br><strong>cat /home/deployer/.ssh/id_rsa</strong> #show private key in terminal, and copy it using mouse</pre><p>If you need more information on this read <a href="https://serversforhackers.com/c/permissions-and-user-management">https://serversforhackers.com/c/permissions-and-user-management</a></p><p><strong>Install gitlab runner</strong></p><p>In GitLab, Runners run the jobs that you define in .gitlab-ci.yml. A Runner can be a virtual machine, a VPS, a bare-metal machine, a docker container or even a cluster of containers. GitLab and the Runners communicate through an API, so the only requirement is that the Runner’s machine has network access to the GitLab server.</p><p>To install the Runner:</p><ul><li>SSH into your remote server</li></ul><pre>ssh root@your_ip_address</pre><ul><li>Add GitLab’s official repository:</li></ul><pre>curl -L https://packages.gitlab.com/install/repositories/runner/gitlab-runner/script.deb.sh | sudo bash</pre><ul><li>Install GitLab Runner</li></ul><pre>sudo apt-get install gitlab-runner</pre><p><strong>Register new gitlab runner</strong></p><pre>sudo gitlab-runner register</pre><p>This command will ask you different questions:</p><pre>Please enter the gitlab-ci coordinator URL (e.g. <a href="https://gitlab.com/">https://gitlab.com/</a>):</pre><p>If you are hosting your repository in your private repository in gitlab just enter “<a href="https://gitlab.com/">https://gitlab.com</a>”</p><pre>Please enter the gitlab-ci token for this runner:</pre><p>There are three types of runners <strong><em>shared</em></strong>, <strong><em>specific</em></strong> and <strong><em>group. </em></strong>More on runners <a href="https://docs.gitlab.com/ee/ci/runners/">https://docs.gitlab.com/ee/ci/runners/</a>. I choose <strong><em>specific runner </em></strong>when registering, so I need it’s token to register on server. In order to get token for specific user. Go to your project and go to <strong>Settings &gt; CI/CD</strong> to obtain the token. This window is like below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/906/1*GFJEGXmVzICG7PxyXHeIAQ.png" /></figure><p>Click <strong>Disable shared Runners. </strong>Otherwise it will run shared preference by default.</p><p>Enter the token in step 3 left side.</p><pre>Please enter the gitlab-ci description for this runner:</pre><p>Description for this project, for example, runner for my project.</p><pre>Please enter the gitlab-ci tags for this runner (comma separated):</pre><p>Any tag that you want to put on this runner. You may skip it.</p><pre>Please enter the executor: docker, docker-ssh, parallels, ssh, virtualbox, kubernetes, shell, docker+machine, docker-ssh+machine:</pre><p>Type <strong><em>ssh </em></strong>in order to select ssh.</p><pre>Please enter the SSH server address (e.g. my.server.com):</pre><p>Type in your server address or ip address.</p><pre>Please enter the SSH server port (e.g. 22):</pre><p>You may skip this one too, if you want.</p><pre>Please enter the SSH user (e.g. root):</pre><p>Type in previously created user name <strong><em>deployer.</em></strong></p><pre>Please enter the SSH password (e.g. docker.io):</pre><p>Enter the password you chose, when creating deployer user.</p><pre>Please enter path to SSH identity file (e.g. /home/user/.ssh/id_rsa):</pre><p>Enter the path to a ssh private key we created above (/home/deployer/.ssh/id_rsa).</p><p>After all these questions you will get below message, if you did everything right.</p><pre>Runner registered successfully. Feel free to start it, but if it&#39;s running already the config should be automatically reloaded!</pre><p>After successfull registration of your, you will see our new specific token added under Specific Tokens on the left side:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/444/1*4eiFqICpawKraRFC-uOLfg.png" /></figure><p><strong>Create <em>.gitlab-ci.yml</em> file</strong></p><blockquote>GitLab CI/CD <a href="https://docs.gitlab.com/ee/ci/pipelines.html">pipelines</a> are configured using a YAML file called .gitlab-ci.yml within each project.</blockquote><blockquote>The .gitlab-ci.yml file defines the structure and order of the pipelines and determines:</blockquote><blockquote>What to execute using <a href="https://docs.gitlab.com/runner/">GitLab Runner</a>.</blockquote><blockquote>What decisions to make when specific conditions are encountered. For example, when a process succeeds or fails.</blockquote><p>If you need more information please refer to this <a href="https://docs.gitlab.com/ee/ci/yaml/README.html">link</a> .</p><p>Checkout to a <strong>develop </strong>branch. Fill out <strong>.env.example </strong>with necessary information according to your database and other needs.</p><p>Now create a file with the name <strong>.gitlab-ci.yml</strong>. Copy and paste following text in it and don’t forget to replace {your-project-name} with your project name. If you place your projects other than /var/www/html/, replace it with path to your own project.</p><pre>before_script:<br>  - echo &quot;Before script&quot;<br>  - cd /var/www/html/{your-project-name} #your project path<br>building:<br>  stage: build<br>  script:<br>    - git reset --hard<br>    - git pull origin develop<br>    - composer install<br>    - cp .env.example .env<br>    - php artisan key:generate<br>    - php artisan migrate --seed<br>    - php artisan cache:clear<br>    - php artisan config:clear<br>    - php artisan storage:link<br>    - sudo chown -R deployer:www-data /var/www/html/{your-project-name}/<br>    - find /var/www/html/{your-project-name} -type f -exec chmod 664 {} \;<br>    - find /var/www/html/{your-project-name} -type d -exec chmod 775 {} \;<br>    - chgrp -R www-data storage bootstrap/cache<br>    - chmod -R ug+rwx storage bootstrap/cache<br>testing:<br>  stage: test<br>  script:<br>    - php ./vendor/bin/phpunit<br>deploying:<br>  stage: deploy<br>  script:<br>    - echo &quot;Deployed&quot;<br>    - php artisan queue:restart #if you use queue</pre><p>This is very simple example of CI CD configuration you are free to change it according to your needs. Script has three stages and one before_script. Before script always run before each stage, i.e. building, testing, deploying. Runner runs first <strong>building</strong> stage, second <strong>testing </strong>adn finally <strong>deploying</strong>.</p><p>After you add and push this file, pipeline starts to deploy automatically. Go to <strong>CI/CD &gt;Pipelines </strong>on your project repository left side panel. Something like these:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*21ARi8Pg_-oynAENlX2UxQ.png" /></figure><p>But it is failed. Hit that red <strong>failed button </strong>and you will go to following page:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g_XUFws3ZWd5DyBxZss0ew.png" /></figure><p>According to above picture, fail is on <strong>building stage. </strong>Click the building button with red circle x on it. Now you are on the snapshot of your terminal. From here you can see what is the cause of this error.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AuRvmRgYBRWmgWhWNan7IA.png" /></figure><p>The error is after <strong>git pull develop</strong>.</p><pre>Host key verification failed.<br>fatal: Could not read from remote repository.<br><br>Please make sure you have the correct access rights<br>and the repository exists.</pre><p>Now you need to login your server with <strong>deployer </strong>user and pull the project manually, if it is the first time you are pulling your repository. Because <strong><em>authenticity of gitlab.com is not established yet.</em></strong></p><p>Make sure that you add your public key into <strong>SSH keys in your settings.</strong></p><p>In order to do this run following command:</p><pre>cat /home/deployer/.ssh/id_rsa.pub</pre><p>Copy the key and paste it in text area for key in your settings page.</p><p>Now go to <strong>CI/CD &gt; Pipelines </strong>and retry pipeline.</p><p>That’s all.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b6de8aa6a611" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>