{"id":402727,"date":"2024-06-29T16:41:27","date_gmt":"2024-06-29T16:41:27","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=402727"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2024-06-29T16:41:27","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=402727","title":{"rendered":"<span>Bash \u0441\u043a\u0440\u0438\u043f\u0442\u044b<\/span>"},"content":{"rendered":"<div><!--[--><!--]--><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p><strong><em>\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u043e\u0439 Linux &amp; Shell \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u0434\u043b\u044f \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0449\u0438\u0445<\/em><\/strong><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/639\/7ca\/da8\/6397cada8401685516535f8f59c76844.png\" width=\"1056\" height=\"622\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/639\/7ca\/da8\/6397cada8401685516535f8f59c76844.png\"\/><\/figure>\n<p>\u0412 Linux \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0432 \u0432 \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0435\u043f\u0435\u043d\u0438 \u0440\u0435\u0448\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438 \u0432 shell \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435. \u042d\u0442\u043e \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442 \u043f\u043e\u0434 \u0441\u043e\u0431\u043e\u0439 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0435\u0433\u043e \u0440\u044f\u0434 \u043a\u043e\u043c\u0430\u043d\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e.<\/p>\n<p>\u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043c \u043e\u0441\u043d\u043e\u0432\u044b \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 bash, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435, \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0432\u0432\u043e\u0434\/\u0432\u044b\u0432\u043e\u0434 \u0438 \u043e\u0442\u043b\u0430\u0434\u043a\u0443. \u041a\u0430\u0436\u0434\u044b\u0439 \u043f\u0443\u043d\u043a\u0442 \u0441\u043e\u043f\u0440\u043e\u0432\u043e\u0434\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u043c\u0438.<\/p>\n<p>\u041d\u0430\u0447\u043d\u0435\u043c.<\/p>\n<h3>\u041e\u0433\u043b\u0430\u0432\u043b\u0435\u043d\u0438\u0435<\/h3>\n<ol>\n<li>\n<p><a href=\"#1\" rel=\"noopener noreferrer nofollow\">\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#2\" rel=\"noopener noreferrer nofollow\">\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435<\/a><\/p>\n<\/li>\n<\/ol>\n<ul>\n<li>\n<p>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/p>\n<\/li>\n<li>\n<p>\u041f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/p>\n<\/li>\n<li>\n<p>\u041e\u0431\u0437\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 Bash \u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/p>\n<\/li>\n<\/ul>\n<p>3.\u00a0<a href=\"#3\" rel=\"noopener noreferrer nofollow\">\u041a\u0430\u043a \u043d\u0430\u0447\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438<\/a><\/p>\n<ul>\n<li>\n<p>\u041a\u0430\u043a \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/p>\n<\/li>\n<li>\n<p><a href=\"#4\" rel=\"noopener noreferrer nofollow\">\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash<\/a><\/p>\n<\/li>\n<\/ul>\n<p>4.\u00a0<a href=\"#5\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u044b Bash \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/a><\/p>\n<ul>\n<li>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0438 \u0442\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 Bash<\/p>\n<\/li>\n<li>\n<p><a href=\"#6\" rel=\"noopener noreferrer nofollow\">\u0412\u0432\u043e\u0434 \u0438 \u0432\u044b\u0432\u043e\u0434 \u0432 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u0445<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#7\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash (echo, read \u0438 \u0442. \u0434.)<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#8\" rel=\"noopener noreferrer nofollow\">\u0423\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b (\u0435\u0441\u043b\u0438\/\u0438\u043d\u0430\u0447\u0435)<\/a><\/p>\n<\/li>\n<\/ul>\n<p>5.<a href=\"#9\" rel=\"noopener noreferrer nofollow\">\u00a0\u0426\u0438\u043a\u043b\u044b \u0438 \u0432\u0435\u0442\u0432\u043b\u0435\u043d\u0438\u044f \u0432 Bash<\/a><\/p>\n<ul>\n<li>\n<p>\u0426\u0438\u043a\u043b While<\/p>\n<\/li>\n<li>\n<p>\u0426\u0438\u043a\u043b For<\/p>\n<\/li>\n<li>\n<p>\u041e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 Case<\/p>\n<\/li>\n<\/ul>\n<p>6.<a href=\"#10\" rel=\"noopener noreferrer nofollow\">\u00a0\u041f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0421ron<\/a><\/p>\n<p>7.\u00a0<a href=\"#11\" rel=\"noopener noreferrer nofollow\">\u041e\u0442\u043b\u0430\u0434\u043a\u0430 \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/a><\/p>\n<p>8.\u00a0\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/p>\n<h3>\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f<\/h3>\n<p><a class=\"anchor\" name=\"1\" id=\"1\"><\/a><\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e\u043c\u0443 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0443, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u043c\u0435\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<p>\u0420\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f Linux \u0441 \u0434\u043e\u0441\u0442\u0443\u043f\u043e\u043c \u043a \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435.<br \/>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d Linux \u0438\u043b\u0438 \u0432\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442\u0435 \u0435\u0433\u043e \u0438\u0437\u0443\u0447\u0430\u0442\u044c, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043b\u0435\u0433\u043a\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 Linux \u0447\u0435\u0440\u0435\u0437 Replit.\u00a0<a href=\"https:\/\/replit.com\/\" rel=\"noopener noreferrer nofollow\"><u>Replit<\/u><\/a>\u00a0\u2014 \u044d\u0442\u043e \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043d\u0430\u044f IDE, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash \u0437\u0430 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u0438\u043d\u0443\u0442.<\/p>\n<p>\u0412\u044b \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u0435\u0442\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c Linux \u043f\u043e\u0432\u0435\u0440\u0445 \u0432\u0430\u0448\u0435\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b Windows, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f WSL (\u043f\u043e\u0434\u0441\u0438\u0441\u0442\u0435\u043c\u0430 Windows \u0434\u043b\u044f Linux). \u0418\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f \u043f\u043e\u00a0<a href=\"https:\/\/learn.microsoft.com\/ru-ru\/windows\/wsl\/install\" rel=\"noopener noreferrer nofollow\"><u>\u0441\u0441\u044b\u043b\u043a\u0435<\/u><\/a>.<\/p>\n<p><a class=\"anchor\" name=\"2\" id=\"2\"><\/a><\/p>\n<h3>\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435<\/h3>\n<p><strong>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/strong><\/p>\n<p>Bash-\u0441\u043a\u0440\u0438\u043f\u0442 \u2014 \u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043e\u0439 bash \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e. \u041e\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0440\u044f\u0434 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439, \u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u043a \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c\u0443 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0443, \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0430\u043f\u043a\u0438 \u0438 \u0437\u0430\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438.<\/p>\n<p>\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0432 \u044d\u0442\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438(\u0441\u043a\u0440\u0438\u043f\u0442\u044b), \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c \u043e\u0434\u043d\u0443 \u0438 \u0442\u0443 \u0436\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0448\u0430\u0433\u043e\u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0440\u0430\u0437 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0438\u0445, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439.<\/p>\n<p><strong>\u041f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/strong><\/p>\n<p>\u0421\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash \u2014 \u044d\u0442\u043e \u043c\u043e\u0449\u043d\u044b\u0439 \u0438 \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u044b\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0433\u043e \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u043c\u0438 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c\u0438 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u0440\u0443\u0433\u0438\u0445 \u0440\u0443\u0442\u0438\u043d\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445 Unix\/Linux. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438:<\/p>\n<ul>\n<li>\n<p><strong>\u0410\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u044f<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u044e\u0449\u0438\u0435\u0441\u044f \u0437\u0430\u0434\u0430\u0447\u0438 \u0438 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u044b, \u044d\u043a\u043e\u043d\u043e\u043c\u044f \u0432\u0440\u0435\u043c\u044f \u0438 \u0441\u043d\u0438\u0436\u0430\u044f \u0440\u0438\u0441\u043a \u043e\u0448\u0438\u0431\u043e\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u0443\u0442\u044c \u043f\u0440\u0438 \u0440\u0443\u0447\u043d\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><strong>\u041f\u043e\u0440\u0442\u0430\u0442\u0438\u0432\u043d\u043e\u0441\u0442\u044c<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043d\u0430 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 \u0438 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445, \u0432\u043a\u043b\u044e\u0447\u0430\u044f Unix, Linux, macOS \u0438 \u0434\u0430\u0436\u0435 Windows, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u044d\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u043e\u0432 \u0438\u043b\u0438 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043c\u0430\u0448\u0438\u043d.<\/p>\n<\/li>\n<li>\n<p><strong>\u0413\u0438\u0431\u043a\u043e\u0441\u0442\u044c<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0438 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u043b\u0435\u0433\u043a\u043e \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u044b \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u043c\u0438 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f\u043c\u0438. \u0418\u0445 \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u044f\u0437\u044b\u043a\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438\u043b\u0438 \u0443\u0442\u0438\u043b\u0438\u0442\u0430\u043c\u0438 \u0434\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0431\u043e\u043b\u0435\u0435 \u043c\u043e\u0449\u043d\u044b\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432.<\/p>\n<\/li>\n<li>\n<p><strong>\u0414\u043e\u0441\u0442\u0443\u043f\u043d\u043e\u0441\u0442\u044c<\/strong>. \u0421\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438 \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0442 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0438\u043b\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e\u0433\u043e \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f. \u0418\u0445 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043b\u044e\u0431\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430, \u0430 \u0432 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c \u0435\u0441\u0442\u044c \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438.<\/p>\n<\/li>\n<li>\n<p><strong>\u0418\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044f<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u0442\u0430\u043a\u0438\u043c\u0438 \u043a\u0430\u043a \u0431\u0430\u0437\u044b \u0434\u0430\u043d\u043d\u044b\u0445, \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440\u044b \u0438 \u043e\u0431\u043b\u0430\u0447\u043d\u044b\u0435 \u0441\u043b\u0443\u0436\u0431\u044b, \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0435\u0448\u0430\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439.<\/p>\n<\/li>\n<li>\n<p><strong>\u041e\u0442\u043b\u0430\u0434\u043a\u0430<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043e\u0442\u043b\u0430\u0436\u0438\u0432\u0430\u0442\u044c, \u0438 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a \u0438\u043c\u0435\u044e\u0442 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0438 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0430\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043c\u043e\u0433\u0430\u044e\u0442 \u0431\u044b\u0441\u0442\u0440\u043e \u0432\u044b\u044f\u0432\u043b\u044f\u0442\u044c \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0442\u044c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b.<\/p>\n<\/li>\n<\/ul>\n<p><strong>\u041e\u0431\u0437\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 Bash \u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/strong><\/p>\n<p>\u0422\u0435\u0440\u043c\u0438\u043d\u044b \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb \u0438 \u00abbash\u00bb \u0432\u0437\u0430\u0438\u043c\u043e\u0437\u0430\u043c\u0435\u043d\u044f\u0435\u043c\u044b. \u041d\u043e \u043c\u0435\u0436\u0434\u0443 \u043d\u0438\u043c\u0438 \u0435\u0441\u0442\u044c \u0442\u043e\u043d\u043a\u0430\u044f \u0440\u0430\u0437\u043d\u0438\u0446\u0430.<\/p>\n<p>\u0422\u0435\u0440\u043c\u0438\u043d \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0441\u044f \u043a \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439. Bash (Bourne Again SHell) \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0447\u0430\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0445 \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a Unix\/Linux \u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u043e\u0439 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432\u043e \u043c\u043d\u043e\u0433\u0438\u0445 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u0430\u0445 Linux.<\/p>\n<p>\u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 zsh \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/200\/495\/fc3\/200495fc334e4fd75c31c17e68a4a318.png\" alt=\"\u041e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\" title=\"\u041e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\" width=\"818\" height=\"122\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/200\/495\/fc3\/200495fc334e4fd75c31c17e68a4a318.png\"\/><\/p>\n<div><figcaption>\u041e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432\u044b\u0432\u043e\u0434<\/figcaption><\/div>\n<\/figure>\n<p>\u0412 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u043c \u0432\u044b\u0448\u0435 \u0432\u044b\u0432\u043e\u0434\u0435 clockber::~>>\u200a\u2014\u200a\u044d\u0442\u043e \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 zsh. \u041a\u043e\u0433\u0434\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435, \u0432 Linux \u043e\u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 $, \u043a\u043e\u0433\u0434\u0430 \u043e\u0436\u0438\u0434\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u0430 \u043e\u0442 \u0438\u043c\u0435\u043d\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f root (\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0441 \u043f\u0440\u0430\u0432\u0430\u043c\u0438 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0430), \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u043d\u0430 #. \u041f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">[root@host ~]#<\/code><\/pre>\n<p>\u0425\u043e\u0442\u044f Bash\u200a\u2014\u200a\u044d\u0442\u043e \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 Korn (ksh), \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 C (csh) \u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 Z (zsh). \u041a\u0430\u0436\u0434\u0430\u044f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0438\u043c\u0435\u0435\u0442 \u0441\u0432\u043e\u0439 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441 \u0438 \u043d\u0430\u0431\u043e\u0440 \u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u043d\u043e \u0432\u0441\u0435 \u043e\u043d\u0438 \u0438\u043c\u0435\u044e\u0442 \u043e\u0431\u0449\u0443\u044e \u0446\u0435\u043b\u044c\u200a\u2014\u200a\u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439.<\/p>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0441\u0432\u043e\u0439 \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b ps:<\/p>\n<pre><code class=\"bash\">ps<\/code><\/pre>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0432\u043e\u0434\u0430 \u043c\u043e\u0435\u0433\u043e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/50d\/d19\/fc9\/50dd19fc9aa17f94677113f971ad8b71.png\" alt=\"\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0442\u0438\u043f\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438. \u042f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 zsh\" title=\"\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0442\u0438\u043f\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438. \u042f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 zsh\" width=\"688\" height=\"212\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/50d\/d19\/fc9\/50dd19fc9aa17f94677113f971ad8b71.png\"\/><\/p>\n<div><figcaption>\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0442\u0438\u043f\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438. \u042f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 zsh<\/figcaption><\/div>\n<\/figure>\n<p>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0432 \u0442\u043e \u0432\u0440\u0435\u043c\u044f \u043a\u0430\u043a \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb\u200a\u2014\u200a\u044d\u0442\u043e \u0448\u0438\u0440\u043e\u043a\u0438\u0439 \u0442\u0435\u0440\u043c\u0438\u043d, \u043e\u0442\u043d\u043e\u0441\u044f\u0449\u0438\u0439\u0441\u044f \u043a \u043b\u044e\u0431\u043e\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0435\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438, \u00abBash\u00bb\u200a\u2014\u200a\u044d\u0442\u043e \u043e\u0441\u043e\u0431\u044b\u0439 \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445 Unix\/Linux.<\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435: \u0432 \u044d\u0442\u043e\u043c \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0435 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 \u00abbash\u00bb.<\/p>\n<p><a class=\"anchor\" name=\"3\" id=\"3\"><\/a><\/p>\n<h3>\u041a\u0430\u043a \u043d\u0430\u0447\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438<\/h3>\n<p><strong>\u041a\u0430\u043a \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/strong><br \/>\u041a\u0430\u043a \u0443\u043f\u043e\u043c\u0438\u043d\u0430\u043b\u043e\u0441\u044c \u0440\u0430\u043d\u0435\u0435, \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">[user@host ~]$<\/code><\/pre>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0432\u0432\u0435\u0441\u0442\u0438 \u043b\u044e\u0431\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u043f\u043e\u0441\u043b\u0435 \u0437\u043d\u0430\u043a\u0430 $ \u0438 \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435.<\/p>\n<p>\u041a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u043e, \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0438\u043c\u0435\u044e\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441:<\/p>\n<pre><code>command [OPTIONS] arguments<\/code><\/pre>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 bash \u0438 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0438\u0445 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b. \u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0438\u0445 \u0432 \u0441\u0432\u043e\u0435\u043c \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435.<\/p>\n<ul>\n<li>\n<p><code>date<\/code>: \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"bash\">admin@user-new:\/$ date Sat 25 Mar 2023 14 12:04:17 PM MSK<\/code><\/pre>\n<ul>\n<li>\n<p><code>pwd<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u0430\u0442\u0430\u043b\u043e\u0433.<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"bash\">admin@user-new:\/usr\/lib$ pwd \/usr\/lib<\/code><\/pre>\n<ul>\n<li>\n<p><code>ls<\/code>: \u0412\u044b\u0432\u043e\u0434\u0438\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<\/li>\n<\/ul>\n<pre><code>admin@user-new:\/home$ ls clockber<\/code><\/pre>\n<ul>\n<li>\n<p><code>echo<\/code>: \u0412\u044b\u0432\u043e\u0434\u0438\u0442 \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u0441\u0442\u0440\u043e\u043a\u0443 \u0442\u0435\u043a\u0441\u0442\u0430 \u0438\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<\/li>\n<\/ul>\n<pre><code>admin@user-new:\/home$ echo \"Hello bash\" Hello bash<\/code><\/pre>\n<p>\u0412\u044b \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442\u0435 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c\u0441\u044f \u043a \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0443 \u043f\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b man.<\/p>\n<p>\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e echo \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/fc6\/725\/e1c\/fc6725e1ce17f488ef9778d27c78e53b.png\" width=\"2500\" height=\"1602\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/fc6\/725\/e1c\/fc6725e1ce17f488ef9778d27c78e53b.png\"\/><\/figure>\n<p><a class=\"anchor\" name=\"4\" id=\"4\"><\/a><\/p>\n<h2>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u00a0Bash<\/h2>\n<p><strong>\u0421\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432<\/strong><\/p>\n<p>\u041f\u043e \u0441\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044e \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 bash \u0437\u0430\u043a\u0430\u043d\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u043d\u0430\u00a0.sh. \u041e\u0434\u043d\u0430\u043a\u043e \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 bash \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0431\u0435\u0437 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u044f sh.<\/p>\n<p><strong>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0428\u0435\u0431\u0430\u043d\u0433(Shebang)<\/strong><\/p>\n<p>\u0421\u043a\u0440\u0438\u043f\u0442\u044b Bash \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0442\u0441\u044f \u0441 \u0448\u0435\u0431\u0430\u043d\u0433\u0430. \u0428\u0435\u0431\u0430\u043d\u0433(Shebang)\u200a\u2014\u200a\u044d\u0442\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0430\u0446\u0438\u044f bash # \u0438 bang\u00a0! \u0437\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043f\u0443\u0442\u044c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 bash. \u042d\u0442\u043e \u043f\u0435\u0440\u0432\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u0441\u043a\u0440\u0438\u043f\u0442\u0430. \u0428\u0435\u0431\u0430\u043d\u0433 \u0433\u043e\u0432\u043e\u0440\u0438\u0442 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0435\u0433\u043e \u0447\u0435\u0440\u0435\u0437 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 bash. Shebang\u200a\u2014\u200a\u044d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0443 bash.<\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d \u043f\u0440\u0438\u043c\u0435\u0440 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0448\u0435\u0431\u0430\u043d\u0433.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash<\/code><\/pre>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u043f\u0443\u0442\u044c \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash (\u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u043e\u0436\u0435\u0442 \u043e\u0442\u043b\u0438\u0447\u0430\u0442\u044c\u0441\u044f \u043e\u0442 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u0432\u044b\u0448\u0435) \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b:<\/p>\n<pre><code class=\"bash\">which bash<\/code><\/pre>\n<p><strong>\u041d\u0430\u0448 \u043f\u0435\u0440\u0432\u044b\u0439 bash-\u0441\u043a\u0440\u0438\u043f\u0442<\/strong><\/p>\n<p>\u041d\u0430\u0448 \u043f\u0435\u0440\u0432\u044b\u0439 \u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0432\u0432\u0435\u0441\u0442\u0438 \u043f\u0443\u0442\u044c. \u0412 \u0441\u0432\u043e\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c \u043e\u043d \u0432\u0435\u0440\u043d\u0435\u0442 \u0432\u0441\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u0444\u0430\u0439\u043b \u0441 \u0438\u043c\u0435\u043d\u0435\u043c show_all.sh \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b <code>vi<\/code>. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440 \u043f\u043e \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u044b\u0431\u043e\u0440\u0443.<\/p>\n<pre><code class=\"bash\">vi show_all.sh<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0441\u0432\u043e\u0439 \u0444\u0430\u0439\u043b \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u0435 \u0435\u0433\u043e:<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash echo \"\u0441\u0435\u0433\u043e\u0434\u043d\u044f \" `date`  echo -e \"\\n \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043f\u0443\u0442\u044c \u043a \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438:\" read path_to  echo -e \"\\n \u0432\u0430\u0448\u0430 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438:\" ls $path_to<\/code><\/pre>\n<p>\u0421\u043a\u0440\u0438\u043f\u0442 \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443 \u0438 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e. \u042f \u0441\u043d\u043e\u0432\u0430 \u043f\u0440\u0438\u0432\u043e\u0436\u0443 \u0442\u043e\u0442 \u0436\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439, \u043d\u043e \u043d\u0430 \u044d\u0442\u043e\u0442 \u0440\u0430\u0437 \u0441 \u043d\u043e\u043c\u0435\u0440\u0430\u043c\u0438 \u0441\u0442\u0440\u043e\u043a.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash echo \"\u0421\u0435\u0433\u043e\u0434\u043d\u044f \" `date`    echo -e \"\\n \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043f\u0443\u0442\u044c \u043a \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438:\" read path_to    echo -e \"\\n \u0432\u0430\u0448\u0430 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438:\" ls $path_to<\/code><\/pre>\n<ul>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #1: \u0428\u0435\u0431\u0430\u043d\u0433 (#!\/bin\/bash) \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430 \u043f\u0443\u0442\u044c \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash.<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #2: \u043a\u043e\u043c\u0430\u043d\u0434\u0430 <code>echo<\/code> \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443 \u0438 \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u0434\u0430\u0442\u0430 \u0443\u043a\u0430\u0437\u0430\u043d\u0430 \u0432 \u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0445 \u043a\u0430\u0432\u044b\u0447\u043a\u0430\u0445.<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #4: \u043c\u044b \u0445\u043e\u0442\u0438\u043c, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0432\u0432\u0435\u043b \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c.\u0421\u0442\u0440\u043e\u043a\u0430 #5: \u041a\u043e\u043c\u0430\u043d\u0434\u0430 \u0447\u0442\u0435\u043d\u0438\u044f \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0432\u0432\u043e\u0434 \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u0442 \u0435\u0433\u043e \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 path_to.<\/p>\n<\/li>\n<li>\n<p>\u0441\u0442\u0440\u043e\u043a\u0430 #8: \u041a\u043e\u043c\u0430\u043d\u0434\u0430 <code>lh<\/code> \u0431\u0435\u0440\u0435\u0442 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e \u0441 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0435 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438.<\/p>\n<\/li>\n<\/ul>\n<p><strong>\u0412\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/strong><\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c, \u043d\u0430\u0437\u043d\u0430\u0447\u044c\u0442\u0435 \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b:<\/p>\n<pre><code class=\"bash\">chmod u+x show_all.sh<\/code><\/pre>\n<p>\u0413\u0434\u0435,<\/p>\n<ul>\n<li>\n<p><code>chmod<\/code> \u0438\u0437\u043c\u0435\u043d\u044f\u0435\u0442 \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0430 \u0444\u0430\u0439\u043b\u0430 \u0434\u043b\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <code>u:<\/code>.<\/p>\n<\/li>\n<li>\n<p><code>+x<\/code> \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c, \u044f\u0432\u043b\u044f\u044e\u0449\u0438\u0439\u0441\u044f \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0435\u043c, \u0442\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439.<\/p>\n<\/li>\n<li>\n<p><code>show_all.sh<\/code>\u200a\u2014\u200a\u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c.<\/p>\n<\/li>\n<\/ul>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442 \u043b\u044e\u0431\u044b\u043c \u0438\u0437 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432:<\/p>\n<ul>\n<li>\n<p><code>sh show_all.sh<\/code><\/p>\n<\/li>\n<li>\n<p><code>bash show_all.sh<\/code><\/p>\n<\/li>\n<li>\n<p><code>.\/show_all.sh<\/code><\/p>\n<\/li>\n<\/ul>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u043e\u043d \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442?<\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07b\/14f\/769\/07b14f769157819eea2a5e135e5ba308.gif\" width=\"480\" height=\"82\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07b\/14f\/769\/07b14f769157819eea2a5e135e5ba308.gif\"\/><\/figure>\n<p><a class=\"anchor\" name=\"5\" id=\"5\"><\/a><\/p>\n<h2>\u041e\u0441\u043d\u043e\u0432\u044b Bash\u00a0\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/h2>\n<p><strong>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash<\/strong><\/p>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0442\u0441\u044f \u0441 # \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043b\u044e\u0431\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430, \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0449\u0430\u044f\u0441\u044f \u0441 #, \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u043c \u0438 \u0431\u0443\u0434\u0435\u0442 \u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u043e\u043c.<\/p>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u043e\u0447\u0435\u043d\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u044b \u043f\u0440\u0438 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u043a\u043e\u0434\u0430, \u0438 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c \u0438\u0445, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043c\u043e\u0447\u044c \u0434\u0440\u0443\u0433\u0438\u043c \u043f\u043e\u043d\u044f\u0442\u044c \u043a\u043e\u0434.<\/p>\n<p>\u0412\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432:<\/p>\n<pre><code class=\"bash\"># This is an example comment # \u041c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0438\u0442\u044c \u043d\u0430 \u0440\u0443\u0441\u0441\u043a\u043e\u043c # These lines will be ignored by the interpreter<\/code><\/pre>\n<p><strong>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0438 \u0442\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 Bash<\/strong><\/p>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f, \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0432\u043e \u0432\u0441\u0435\u043c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438.<\/p>\n<p>\u0412 Bash \u043d\u0435\u0442 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445. \u0412 Bash \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043c\u043e\u0436\u0435\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0447\u0438\u0441\u043b\u043e\u0432\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0438\u043b\u0438 \u0441\u0442\u0440\u043e\u043a\u0438 \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432.<\/p>\n<p>\u0412 Bash \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438:<\/p>\n<ol>\n<li>\n<p>\u041d\u0430\u0437\u043d\u0430\u0447\u044c\u0442\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e:<\/p>\n<\/li>\n<\/ol>\n<pre><code class=\"bash\">country=Russia<\/code><\/pre>\n<p>2. \u041f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0432\u044b\u0432\u043e\u0434\u0430, \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u043e\u0433\u043e \u043e\u0442 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u043a\u043e\u043c\u0430\u043d\u0434. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e $ \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<pre><code class=\"bash\">same_country=$country<\/code><\/pre>\n<p>\u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439, \u0434\u043e\u0431\u0430\u0432\u044c\u0442\u0435 $ \u043a \u0438\u043c\u0435\u043d\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<pre><code class=\"bash\">admin@user-new:\/$ country=Russia admin@user-new:\/$ echo $country Russia admin@user-new:\/$ new_country=$country admin@user-new:\/$ echo $new_country Russia<\/code><\/pre>\n<p><strong>\u0421\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445<\/strong><\/p>\n<p>\u0412 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 Bash \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445:<\/p>\n<ol>\n<li>\n<p>\u0418\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0434\u043e\u043b\u0436\u043d\u044b \u043d\u0430\u0447\u0438\u043d\u0430\u0442\u044c\u0441\u044f \u0441 \u0431\u0443\u043a\u0432\u044b \u0438\u043b\u0438 \u0441\u0438\u043c\u0432\u043e\u043b\u0430 \u043f\u043e\u0434\u0447\u0435\u0440\u043a\u0438\u0432\u0430\u043d\u0438\u044f (<em>).<\/em><\/p>\n<\/li>\n<li>\n<p><em>\u0418\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u043c\u043e\u0433\u0443\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0431\u0443\u043a\u0432\u044b, \u0446\u0438\u0444\u0440\u044b \u0438 \u0441\u0438\u043c\u0432\u043e\u043b\u044b \u043f\u043e\u0434\u0447\u0435\u0440\u043a\u0438\u0432\u0430\u043d\u0438\u044f (<\/em>).<\/p>\n<\/li>\n<li>\n<p>\u0418\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0447\u0443\u0432\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u044b \u043a \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0443.<\/p>\n<\/li>\n<li>\n<p>\u0418\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043f\u0440\u043e\u0431\u0435\u043b\u043e\u0432 \u0438\u043b\u0438 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432.<\/p>\n<\/li>\n<li>\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u043f\u0438\u0441\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0438\u043c\u0435\u043d\u0430, \u043e\u0442\u0440\u0430\u0436\u0430\u044e\u0449\u0438\u0435 \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<\/li>\n<li>\n<p>\u0418\u0437\u0431\u0435\u0433\u0430\u0439\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u0430\u0440\u0435\u0437\u0435\u0440\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u0445 \u0441\u043b\u043e\u0432, \u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a if, then, else, fi \u0438 \u0442. \u0434., \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0438\u043c\u0435\u043d \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445.<\/p>\n<\/li>\n<\/ol>\n<p>\u0412\u043e\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432 \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0445 \u0438\u043c\u0435\u043d \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0432 Bash:<\/p>\n<pre><code class=\"bash\">name count _var myVar MY_VAR<\/code><\/pre>\n<p>\u0410 \u0432\u043e\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432 \u043d\u0435\u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0445 \u0438\u043c\u0435\u043d \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445:<\/p>\n<pre><code>2ndvar (\u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442\u0441\u044f \u0441 \u0446\u0438\u0444\u0440\u044b) my var (\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043f\u0440\u043e\u0431\u0435\u043b) my-var (\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0434\u0435\u0444\u0438\u0441)<\/code><\/pre>\n<p>\u0421\u043e\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u044d\u0442\u0438\u0445 \u0441\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0439 \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u043f\u043e\u043c\u043e\u0433\u0430\u0435\u0442 \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash \u0431\u043e\u043b\u0435\u0435 \u0447\u0438\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0438 \u043f\u0440\u043e\u0441\u0442\u044b\u043c\u0438 \u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438.<\/p>\n<p><a class=\"anchor\" name=\"6\" id=\"6\"><\/a><\/p>\n<h2>\u0412\u0432\u043e\u0434 \u0438 \u0432\u044b\u0432\u043e\u0434 \u0432 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u0445<\/h2>\n<p><strong>\u041e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0430 \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445<\/strong><\/p>\n<p>\u0412 \u044d\u0442\u043e\u043c \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u0432\u0432\u043e\u0434\u0430 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u043d\u0430\u0448\u0438 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438.<\/p>\n<ol>\n<li>\n<p>\u0427\u0442\u0435\u043d\u0438\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0432\u0432\u043e\u0434\u0430 \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u0435\u0433\u043e \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439<\/p>\n<\/li>\n<\/ol>\n<p>\u041c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u0438\u0439 \u0432\u0432\u043e\u0434 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0447\u0442\u0435\u043d\u0438\u044f.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash  echo -e \"\\n Enter your name:\" read the_name  echo -e \"\\n welcome to Medium $the_name\"<\/code><\/pre>\n<p>\u0432\u044b\u0432\u043e\u0434:<\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3d7\/b19\/797\/3d7b19797c1632b72e918ce09cbb4dff.gif\" width=\"480\" height=\"106\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3d7\/b19\/797\/3d7b19797c1632b72e918ce09cbb4dff.gif\"\/><\/figure>\n<p>2. \u0427\u0442\u0435\u043d\u0438\u0435 \u0438\u0437 \u0444\u0430\u0439\u043b\u0430<\/p>\n<p>\u042d\u0442\u043e\u0442 \u043a\u043e\u0434 \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u043a\u0430\u0436\u0434\u0443\u044e \u0441\u0442\u0440\u043e\u043a\u0443 \u0438\u0437 \u0444\u0430\u0439\u043b\u0430 \u0441 \u0438\u043c\u0435\u043d\u0435\u043c input.txt \u0438 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u0435\u0435 \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b. \u041c\u044b \u0438\u0437\u0443\u0447\u0438\u043c \u0446\u0438\u043a\u043b\u044b while \u043f\u043e\u0437\u0436\u0435 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435.<\/p>\n<pre><code class=\"bash\">while read line do   echo $line done &lt; input.txt<\/code><\/pre>\n<p>3. \u0410\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/p>\n<p>\u0412 \u0441\u043a\u0440\u0438\u043f\u0442\u0435 \u0438\u043b\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 bash $1 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u044b\u0439 \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u044b\u0439 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442, $2 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u044b\u0439 \u0432\u0442\u043e\u0440\u043e\u0439 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435.<\/p>\n<p>\u042d\u0442\u043e\u0442 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0438\u043c\u044f \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0438 \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442 \u043f\u0435\u0440\u0441\u043e\u043d\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u043f\u0440\u0438\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435.<\/p>\n<pre><code class=\"bash\">echo \"Hello, $1!\"<\/code><\/pre>\n<p>\u041c\u044b \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u043c \u0441\u043a\u0440\u0438\u043f\u0442\u0443 <code>clockber<\/code> \u043a\u0430\u043a \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash echo \"Hello, $1!\"<\/code><\/pre>\n<p>\u0432\u044b\u0432\u043e\u0434:<\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1d9\/8d3\/3ba\/1d98d33ba2ea0a24eab305205abf0768.gif\" width=\"480\" height=\"102\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1d9\/8d3\/3ba\/1d98d33ba2ea0a24eab305205abf0768.gif\"\/><\/figure>\n<p><strong>\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0432\u044b\u0432\u043e\u0434\u0430<\/strong><\/p>\n<p>\u0417\u0434\u0435\u0441\u044c \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438\u0437 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432.<\/p>\n<ol>\n<li>\n<p>\u041f\u0435\u0447\u0430\u0442\u044c \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b:<\/p>\n<\/li>\n<\/ol>\n<pre><code class=\"bash\">echo \"Hello, World!\"<\/code><\/pre>\n<p>\u042d\u0442\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 \u043d\u0430\u043f\u0435\u0447\u0430\u0442\u0430\u0435\u043c \u0442\u0435\u043a\u0441\u0442 \u201cHello, World!\u201d \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435.<\/p>\n<p>2. \u0417\u0430\u043f\u0438\u0441\u044c \u0432 \u0444\u0430\u0439\u043b:<\/p>\n<pre><code class=\"bash\">echo \"let's write text.\" > output.txt<\/code><\/pre>\n<p>\u042d\u0442\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u0437\u0430\u043f\u0438\u0448\u0435\u0442 \u0442\u0435\u043a\u0441\u0442 \u201clet\u2019s write text.\u201d \u0432 \u0444\u0430\u0439\u043b \u0441 \u0438\u043c\u0435\u043d\u0435\u043c output.txt. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 > \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0438\u0448\u0435\u0442 \u0444\u0430\u0439\u043b, \u0435\u0441\u043b\u0438 \u0432 \u043d\u0435\u043c \u0443\u0436\u0435 \u0435\u0441\u0442\u044c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435.<\/p>\n<p>3. \u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432 \u0444\u0430\u0439\u043b:<\/p>\n<pre><code class=\"bash\">echo \"More text.\" >> output.txt<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0442\u0435\u043a\u0441\u0442 \u201cMore text.\u201d \u0432 \u043a\u043e\u043d\u0435\u0446 \u0444\u0430\u0439\u043b\u0430 output.txt.<\/p>\n<p>4. \u041f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u044b\u0432\u043e\u0434\u0430:<\/p>\n<pre><code class=\"bash\">ls > files.txt<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0435\u043c \u0444\u0430\u0439\u043b\u044b \u0432 \u0442\u0435\u043a\u0443\u0449\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0438 \u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u0432\u044b\u0432\u043e\u0434 \u0432 \u0444\u0430\u0439\u043b \u0441 \u0438\u043c\u0435\u043d\u0435\u043c files.txt. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0432\u044b\u0432\u043e\u0434 \u043b\u044e\u0431\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0444\u0430\u0439\u043b.<\/p>\n<p><a class=\"anchor\" name=\"7\" id=\"7\"><\/a><\/p>\n<h2>\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash (echo, read \u0438 \u0442.\u00a0\u0434.)<\/h2>\n<p>\u0412\u043e\u0442 \u0441\u043f\u0438\u0441\u043e\u043a \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0447\u0430\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 bash:<\/p>\n<ol>\n<li>\n<p><code>cd<\/code>: \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u043d\u0430 \u0434\u0440\u0443\u0433\u0443\u044e.<\/p>\n<\/li>\n<li>\n<p><code>ls<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e \u0432 \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>mkdir<\/code>: \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043d\u043e\u0432\u043e\u0439 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>touch<\/code>: \u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u0439 \u0444\u0430\u0439\u043b.<\/p>\n<\/li>\n<li>\n<p><code>rm<\/code>: \u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 \u0438\u043b\u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>cp<\/code>: \u041a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 \u0438\u043b\u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>mv<\/code>: \u041f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0438\u043b\u0438 \u043f\u0435\u0440\u0435\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 \u0438\u043b\u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>echo<\/code>: \u041f\u0435\u0447\u0430\u0442\u044c \u0442\u0435\u043a\u0441\u0442\u0430 \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b.<\/p>\n<\/li>\n<li>\n<p><code>cat<\/code>: \u0427\u0438\u0442\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0438\u0437 \u0444\u0430\u0439\u043b\u0430 \u0438 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u0438\u0445 \u043d\u0430 \u044d\u043a\u0440\u0430\u043d.<\/p>\n<\/li>\n<li>\n<p><code>grep<\/code>: \u041f\u043e\u0438\u0441\u043a \u0432 \u0444\u0430\u0439\u043b\u0430\u0445.<\/p>\n<\/li>\n<li>\n<p><code>chmod<\/code>: \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u0430\u0432 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0444\u0430\u0439\u043b\u0443 \u0438\u043b\u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><code>sudo<\/code>: \u0417\u0430\u043f\u0443\u0441\u043a \u043a\u043e\u043c\u0430\u043d\u0434 \u0441 \u043f\u0440\u0430\u0432\u0430\u043c\u0438 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0430.<\/p>\n<\/li>\n<li>\n<p><code>df<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0434\u0438\u0441\u043a\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430.<\/p>\n<\/li>\n<li>\n<p><code>history<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0438\u0441\u0442\u043e\u0440\u0438\u0438 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0445 \u043a\u043e\u043c\u043c\u0430\u043d\u0434.<\/p>\n<\/li>\n<li>\n<p><code>ps<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430\u0445.<\/p>\n<\/li>\n<\/ol>\n<p><a class=\"anchor\" name=\"8\" id=\"8\"><\/a><\/p>\n<h2>\u0423\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b (if\/else)<\/h2>\n<p>\u0412\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u044f, \u0434\u0430\u044e\u0449\u0438\u0435 \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442, \u0438\u0441\u0442\u0438\u043d\u043d\u044b\u0439 \u0438\u043b\u0438 \u043b\u043e\u0436\u043d\u044b\u0439, \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u043c\u0438. \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u043e\u0446\u0435\u043d\u043a\u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u0439, \u0432\u043a\u043b\u044e\u0447\u0430\u044f <code>if<\/code>, <code>if-else<\/code>, <code>if-elif-else<\/code> \u0438 \u0432\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0435 \u0443\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b.<\/p>\n<p>\u0421\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441:<\/p>\n<pre><code class=\"bash\">if [[ condition ]]; then  statement elif [[ condition ]]; then  statement  else  do this by default fi<\/code><\/pre>\n<p>\u041c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a AND <code>-a<\/code>\u0438 OR <code>-o<\/code>, \u0447\u0442\u043e\u0431\u044b \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u043c\u0435\u044e\u0442 \u0431\u043e\u043b\u044c\u0448\u0435\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435.<\/p>\n<pre><code class=\"bash\">if [ $a -gt 60 -a $b -lt 100 ]<\/code><\/pre>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f Bash, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b <code>if<\/code>, <code>if-else<\/code>, <code>if-elif-else<\/code>, \u0447\u0442\u043e\u0431\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c, \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u0438 \u0432\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0447\u0438\u0441\u043b\u043e \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c, \u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u043c \u0438\u043b\u0438 \u043d\u0443\u043b\u0435\u0432\u044b\u043c:<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash  echo \"Please enter a number: \" read num  if [ $num -gt 0 ]; then   echo \"$num is positive\" elif [ $num -lt 0 ]; then   echo \"$num is negative\" else   echo \"$num is zero\" fi<\/code><\/pre>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0432\u0432\u0435\u0441\u0442\u0438 \u0447\u0438\u0441\u043b\u043e. \u0417\u0430\u0442\u0435\u043c \u043e\u043d \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 <code>if<\/code>, \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c, \u0431\u043e\u043b\u044c\u0448\u0435 \u043b\u0438 \u0447\u0438\u0441\u043b\u043e, \u0447\u0435\u043c 0. \u0415\u0441\u043b\u0438 \u044d\u0442\u043e \u0442\u0430\u043a, \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u0432\u044b\u0432\u043e\u0434\u0438\u0442, \u0447\u0442\u043e \u0447\u0438\u0441\u043b\u043e \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435. \u0415\u0441\u043b\u0438 \u0447\u0438\u0441\u043b\u043e \u043d\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 0, \u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u0442 \u043a \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c\u0443 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0443, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u043c <code>if-elif<\/code>. \u0417\u0434\u0435\u0441\u044c \u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442, \u043c\u0435\u043d\u044c\u0448\u0435 \u043b\u0438 \u0447\u0438\u0441\u043b\u043e 0. \u0415\u0441\u043b\u0438 \u0434\u0430, \u0442\u043e \u0441\u043a\u0440\u0438\u043f\u0442 \u0432\u044b\u0432\u043e\u0434\u0438\u0442 \u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e. \u041d\u0430\u043a\u043e\u043d\u0435\u0446, \u0435\u0441\u043b\u0438 \u0447\u0438\u0441\u043b\u043e \u043d\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 0 \u0438 \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 0, \u0441\u043a\u0440\u0438\u043f\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 <code>else<\/code> \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u0447\u0438\u0441\u043b\u043e \u0440\u0430\u0432\u043d\u043e \u043d\u0443\u043b\u044e.<\/p>\n<p><a class=\"anchor\" name=\"9\" id=\"9\"><\/a><\/p>\n<h2>\u0426\u0438\u043a\u043b\u044b \u0438 \u0432\u0435\u0442\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u00a0Bash<\/h2>\n<p><strong>\u0426\u0438\u043a\u043b While<\/strong><\/p>\n<p>\u0426\u0438\u043a\u043b\u044b while \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u044e\u0442 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 \u0432 \u0446\u0438\u043a\u043b\u0435, \u043f\u043e\u043a\u0430 \u044d\u0442\u043e \u0443\u0441\u043b\u043e\u0432\u0438\u0435 \u043e\u0441\u0442\u0430\u0435\u0442\u0441\u044f <code>true<\/code>. \u0414\u043b\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0446\u0438\u043a\u043b\u043e\u043c \u043f\u0440\u0438\u043d\u044f\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0447\u0435\u0442\u0447\u0438\u043a\u0438.<\/p>\n<p>\u0412 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u043c \u043d\u0438\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 (( i += 1 ))\u200a\u2014\u200a\u044d\u0442\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u0441\u0447\u0435\u0442\u0447\u0438\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 i. \u0426\u0438\u043a\u043b \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0440\u043e\u0432\u043d\u043e 10 \u0440\u0430\u0437.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash i=1 while [[ $i -le 10 ]] ; do    echo \"$i\"   (( i += 1 )) done<\/code><\/pre>\n<p><strong>\u0426\u0438\u043a\u043b For<\/strong><\/p>\n<p>\u0426\u0438\u043a\u043b for, \u043a\u0430\u043a \u0438 \u0446\u0438\u043a\u043b while, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0440\u0430\u0437. \u041a\u0430\u0436\u0434\u044b\u0439 \u0446\u0438\u043a\u043b \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u0441\u0432\u043e\u0438\u043c \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441\u043e\u043c \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c.<\/p>\n<p>\u0412 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u043c \u043d\u0438\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0446\u0438\u043a\u043b \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u0442\u0441\u044f 5 \u0440\u0430\u0437.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash  for i in {1..5} do     echo $i done<\/code><\/pre>\n<p><strong>\u041e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 Case <\/strong><\/p>\n<p>\u0412 Bash \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b case \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0434\u043b\u044f \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0441\u043e \u0441\u043f\u0438\u0441\u043a\u043e\u043c \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0431\u043b\u043e\u043a\u0430 \u043a\u043e\u0434\u0430 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0441\u043e\u0432\u043f\u0430\u0432\u0449\u0435\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430. \u0421\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 case \u0432 Bash \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439:<\/p>\n<pre><code class=\"bash\">case expression in     pattern1)         # code to execute if expression matches pattern1         ;;     pattern2)         # code to execute if expression matches pattern2         ;;     pattern3)         # code to execute if expression matches pattern3         ;;     *)         # code to execute if none of the above patterns match expression         ;; esac<\/code><\/pre>\n<p>\u0417\u0434\u0435\u0441\u044c <code>expression<\/code>\u2014 \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c, \u0430 <code>pattern1<\/code>, <code>pattern2<\/code>, <code>pattern3<\/code> \u0438 \u0442. \u0434.\u200a\u2014\u200a\u044d\u0442\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u044b, \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0435\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c.<\/p>\n<p>\u0414\u0432\u043e\u0439\u043d\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u0441 \u0437\u0430\u043f\u044f\u0442\u043e\u0439 \u201c;;\u201d \u043e\u0442\u0434\u0435\u043b\u044f\u0435\u0442 \u043a\u0430\u0436\u0434\u044b\u0439 \u0431\u043b\u043e\u043a \u043a\u043e\u0434\u0430 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430. \u0417\u0432\u0435\u0437\u0434\u043e\u0447\u043a\u0430 \u201c*\u201d \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043b\u0443\u0447\u0430\u0439 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f, \u0435\u0441\u043b\u0438 \u043d\u0438 \u043e\u0434\u0438\u043d \u0438\u0437 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u043d\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u044e.<\/p>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440.<\/p>\n<pre><code>fruit=\"apple\"case in    \"apple\")        echo \"This is a red fruit.\"        ;;    \"banana\")        echo \"This is a yellow fruit.\"        ;;    \"orange\")        echo \"This is an orange fruit.\"        ;;    *)        echo \"Unknown fruit.\"        ;;esac<\/code><\/pre>\n<p>\u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u201cfruit\u201d \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u201capple\u201d, \u0447\u0435\u043c\u0443 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u0435\u0440\u0432\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d \u0438 \u0431\u043b\u043e\u043a \u043a\u043e\u0434\u0430, \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435 \u043c\u044b \u0443\u0432\u0438\u0434\u0435\u043c \u201cThis is a red fruit.\u201d. \u0415\u0441\u043b\u0438 \u0431\u044b \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \u201cfruit\u201d \u0431\u044b\u043b\u043e \u201cbanana\u201d, \u0432\u0442\u043e\u0440\u043e\u0439 \u0448\u0430\u0431\u043b\u043e\u043d \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u043b \u0431\u044b \u0438 \u0431\u043b\u043e\u043a\u0443 \u043a\u043e\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u0442 \u201cThis is a yellow fruit.\u201d. \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u0415\u0441\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u201cfruit\u201d\u043d\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u0443\u0447\u0430\u0439 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u0442 \u201cUnknown fruit.\u201d.<\/p>\n<p><a class=\"anchor\" name=\"10\" id=\"10\"><\/a><\/p>\n<h2>\u041f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e\u00a0\u0421ron<\/h2>\n<p>Cron\u200a\u2014\u200a\u043c\u043e\u0449\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u043d\u0438\u0439, \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430\u044f \u0432 Unix-\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0432 cron, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0437\u0430\u0434\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0435\u0436\u0435\u0434\u043d\u0435\u0432\u043d\u043e, \u0435\u0436\u0435\u043d\u0435\u0434\u0435\u043b\u044c\u043d\u043e, \u0435\u0436\u0435\u043c\u0435\u0441\u044f\u0447\u043d\u043e \u0438\u043b\u0438 \u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f. \u0412\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 cron, \u0438\u0433\u0440\u0430\u044e\u0442 \u0440\u0435\u0448\u0430\u044e\u0449\u0443\u044e \u0440\u043e\u043b\u044c \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u043c \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 Linux.<\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441 \u0434\u043b\u044f \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f crons:<\/p>\n<pre><code># Cron job example* * * * * sh \/path\/to\/script.sh<\/code><\/pre>\n<p>\u0417\u0434\u0435\u0441\u044c * \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442 \u0441\u043e\u0431\u043e\u0439 \u043c\u0438\u043d\u0443\u0442\u044b (\u043c\u0438\u043d\u0443\u0442\u044b), \u0447\u0430\u0441\u044b (\u0447\u0430\u0441\u044b), \u0434\u0435\u043d\u044c (\u0434\u043d\u0438), \u043c\u0435\u0441\u044f\u0446\u044b \u0438 \u0434\u043d\u0438 \u043d\u0435\u0434\u0435\u043b\u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e.<\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u044b \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432 \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u043d\u0438\u0439 cron.<\/p>\n<pre><code>schedule    description                                          example0 0 * * *   Run a script at midnight every day                   0 0 * * * \/path\/to\/script.sh*\/5 * * * * Run a script every 5 minutes                         *\/5 * * * * \/path\/to\/script.sh0 6 * * 1-5 Run a script at 6 am from Monday  to Friday          0 6 * * 1-5 \/path\/to\/script.sh0 0 1-7 * * Run a script on the first 7 days of every month      0 0 1-7 * * \/path\/to\/script.sh0 12 1 * *  Run a script on the first day of every month at noon<\/code><\/pre>\n<p><strong>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 crontab<\/strong><br \/>\u0423\u0442\u0438\u043b\u0438\u0442\u0430 crontab \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u043d\u0438\u0439 cron.<\/p>\n<p><code>crontab -l<\/code> \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u0443\u0436\u0435 \u0437\u0430\u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0434\u043b\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c \u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c cron \u0447\u0435\u0440\u0435\u0437 <code>crontab -e<\/code>.<\/p>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435 \u043e \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 Cron \u0437\u0434\u0435\u0441\u044c.<\/p>\n<p><a class=\"anchor\" name=\"11\" id=\"11\"><\/a><\/p>\n<h2>\u041a\u0430\u043a \u043e\u0442\u043b\u0430\u0436\u0438\u0432\u0430\u0442\u044c \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0442\u044c \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043a\u0438 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/h2>\n<p>\u041e\u0442\u043b\u0430\u0434\u043a\u0430 \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0432\u0430\u0436\u043d\u044b\u043c\u0438 \u043d\u0430\u0432\u044b\u043a\u0430\u043c\u0438 \u0434\u043b\u044f \u043b\u044e\u0431\u043e\u0433\u043e Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0440\u0430. \u0425\u043e\u0442\u044f \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u043c\u043e\u0449\u043d\u044b\u043c\u0438, \u043e\u043d\u0438 \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u043f\u043e\u0434\u0432\u0435\u0440\u0436\u0435\u043d\u044b \u043e\u0448\u0438\u0431\u043a\u0430\u043c \u0438 \u043d\u0435\u043e\u0436\u0438\u0434\u0430\u043d\u043d\u043e\u043c\u0443 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u044e. \u0412 \u044d\u0442\u043e\u043c \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043e\u0432\u0435\u0442\u044b \u0438 \u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e \u043e\u0442\u043b\u0430\u0434\u043a\u0435 \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u044e \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 Bash.<\/p>\n<p><strong>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 set -x<\/strong><\/p>\n<p>\u041e\u0434\u0438\u043d \u0438\u0437 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 Bash\u200a\u2014\u200a\u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 set -x \u0432 \u043d\u0430\u0447\u0430\u043b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f. \u042d\u0442\u0430 \u043e\u043f\u0446\u0438\u044f \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0440\u0435\u0436\u0438\u043c \u043e\u0442\u043b\u0430\u0434\u043a\u0438, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c Bash \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442 \u043a\u0430\u0436\u0434\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043e\u043d \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442, \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b, \u043f\u0435\u0440\u0435\u0434 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0441\u0442\u0430\u0432\u0438\u0442\u0441\u044f \u0437\u043d\u0430\u043a +. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0434\u043b\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0442\u043e\u0433\u043e, \u0433\u0434\u0435 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u044e\u0442 \u043e\u0448\u0438\u0431\u043a\u0438.<\/p>\n<pre><code>#!\/bin\/bashset -x# Your script goes here<\/code><\/pre>\n<p><strong>\u041f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u043a\u043e\u0434 \u0432\u044b\u0445\u043e\u0434\u0430<\/strong><\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 Bash \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0432\u0430\u0435\u0442 \u043e\u0448\u0438\u0431\u043a\u0443, \u043e\u043d \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u043a\u043e\u0434 \u0432\u044b\u0445\u043e\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440 \u043e\u0448\u0438\u0431\u043a\u0438. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u043a\u043e\u0434 \u0432\u044b\u0445\u043e\u0434\u0430 \u0441\u0430\u043c\u043e\u0439 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f $? \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f. \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 0 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430 \u0443\u0441\u043f\u0435\u0445, \u0430 \u043b\u044e\u0431\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430 \u043e\u0448\u0438\u0431\u043a\u0443.<\/p>\n<pre><code>#!\/bin\/bash# Your script goes hereif [ $? -ne 0 ]; then    echo \"Error occurred.\"fi<\/code><\/pre>\n<p><strong>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b echo<\/strong><\/p>\n<p>\u0414\u0440\u0443\u0433\u043e\u0439 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432 Bash\u200a\u2014\u200a\u0432\u0441\u0442\u0430\u0432\u043a\u0430 echo-\u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0432 \u0432\u0430\u0448 \u043a\u043e\u0434. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u043c\u043e\u0447\u044c \u0432\u0430\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c, \u0433\u0434\u0435 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u044e\u0442 \u043e\u0448\u0438\u0431\u043a\u0438 \u0438 \u043a\u0430\u043a\u0438\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0434\u0430\u044e\u0442\u0441\u044f \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435.<\/p>\n<pre><code>#!\/bin\/bash# Your script goes hereecho \"Value of variable x is: \" class=\"formula inline\">x\"# More code goes here<\/code><\/pre>\n<p><strong>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u043f\u0446\u0438\u044e set -e<\/strong><\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435, \u0447\u0442\u043e\u0431\u044b \u0432\u0430\u0448 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u043b\u0441\u044f \u043d\u0435\u043c\u0435\u0434\u043b\u0435\u043d\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u043a\u0430\u043a\u0430\u044f-\u043b\u0438\u0431\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043d\u0435 \u0443\u0434\u0430\u043b\u0430\u0441\u044c, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u043f\u0446\u0438\u044e set -e. \u042d\u0442\u043e\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u0437\u0430\u0441\u0442\u0430\u0432\u0438\u0442 Bash \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0441 \u043e\u0448\u0438\u0431\u043a\u043e\u0439, \u0435\u0441\u043b\u0438 \u043a\u0430\u043a\u0430\u044f-\u043b\u0438\u0431\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u0441\u044f \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u043e, \u0447\u0442\u043e \u0443\u043f\u0440\u043e\u0441\u0442\u0438\u0442 \u0432\u044b\u044f\u0432\u043b\u0435\u043d\u0438\u0435 \u0438 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0448\u0438\u0431\u043e\u043a \u0432 \u0432\u0430\u0448\u0435\u043c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438.<\/p>\n<pre><code>#!\/bin\/bashset -e# Your script goes here<\/code><\/pre>\n<p><strong>\u0423\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a Cron \u043f\u0443\u0442\u0435\u043c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 log \u0436\u0443\u0440\u043d\u0430\u043b\u043e\u0432<\/strong><\/p>\n<p>\u041c\u044b \u043c\u043e\u0436\u0435\u043c \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0442\u044c \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043a\u0438 crons \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0430\u0439\u043b\u043e\u0432 \u0436\u0443\u0440\u043d\u0430\u043b\u0430. \u0416\u0443\u0440\u043d\u0430\u043b\u044b \u0432\u0435\u0434\u0443\u0442\u0441\u044f \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0437\u0430\u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u043d\u0438\u0439. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0432 \u0436\u0443\u0440\u043d\u0430\u043b\u0430\u0445, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u043b\u043e\u0441\u044c \u043b\u0438 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0435 \u0437\u0430\u0434\u0430\u043d\u0438\u0435 \u0434\u043e\u043b\u0436\u043d\u044b\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0438\u043b\u0438 \u043d\u0435\u0442.<\/p>\n<p>\u0414\u043b\u044f Ubuntu\/Debian \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 cronlogs \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443:<\/p>\n<pre><code>\/var\/log\/syslog<\/code><\/pre>\n<p>\u0420\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0434\u0440\u0443\u0433\u0438\u0445 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u043e\u0432.<\/p>\n<p>\u0424\u0430\u0439\u043b \u0436\u0443\u0440\u043d\u0430\u043b\u0430 \u0437\u0430\u0434\u0430\u043d\u0438\u0439 cron \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code>2022-03-11 00:00:01 Task started2022-03-11 00:00:02 Running script \/path\/to\/script.sh2022-03-11 00:00:03 Script completed successfully2022-03-11 00:05:01 Task started2022-03-11 00:05:02 Running script \/path\/to\/script.sh2022-03-11 00:05:03 Error: unable to connect to database2022-03-11 00:05:03 Script exited with error code 12022-03-11 00:10:01 Task started2022-03-11 00:10:02 Running script \/path\/to\/script.sh2022-03-11 00:10:03 Script completed successfully<\/code><\/pre>\n<h2>\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h2>\n<p>\u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u044b \u043d\u0430\u0447\u0430\u043b\u0438 \u0441 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0443, \u0430 \u0437\u0430\u0442\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043b\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b bash. \u0422\u0430\u043a\u0436\u0435 \u0438\u0437\u0443\u0447\u0438\u043b\u0438, \u0447\u0442\u043e \u0442\u0430\u043a\u043e\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 bash. \u041a\u0440\u0430\u0442\u043a\u043e \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043b\u0438 \u0432\u0435\u0442\u0432\u043b\u0435\u043d\u0438\u0435 \u043a\u043e\u0434\u0430 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0446\u0438\u043a\u043b\u043e\u0432 \u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u0439. \u041d\u0430\u043a\u043e\u043d\u0435\u0446, \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043b\u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u044e \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cron, \u0430 \u0437\u0430\u0442\u0435\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a.<\/p>\n<p>\u041d\u0430\u0434\u0435\u044e\u0441\u044c \u0432\u0441\u044f \u0432\u044b\u0448\u0435\u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u043d\u0430\u044f \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0432\u0430\u043c \u043f\u043e\u043c\u043e\u0433\u043b\u0430\u00a0\ud83d\ude42<\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<p><!----><!----><\/div>\n<p><!----><!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/726316\/\"> https:\/\/habr.com\/ru\/articles\/726316\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><!--[--><!--]--><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p><strong><em>\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u043e\u0439 Linux &amp; Shell \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u0434\u043b\u044f \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0449\u0438\u0445<\/em><\/strong><\/p>\n<figure class=\"full-width\"><\/figure>\n<p>\u0412 Linux \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0432 \u0432 \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0435\u043f\u0435\u043d\u0438 \u0440\u0435\u0448\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438 \u0432 shell \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435. \u042d\u0442\u043e \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442 \u043f\u043e\u0434 \u0441\u043e\u0431\u043e\u0439 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0435\u0433\u043e \u0440\u044f\u0434 \u043a\u043e\u043c\u0430\u043d\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e.<\/p>\n<p>\u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u044b \u043e\u0431\u0441\u0443\u0434\u0438\u043c \u043e\u0441\u043d\u043e\u0432\u044b \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 bash, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435, \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0432\u0432\u043e\u0434\/\u0432\u044b\u0432\u043e\u0434 \u0438 \u043e\u0442\u043b\u0430\u0434\u043a\u0443. \u041a\u0430\u0436\u0434\u044b\u0439 \u043f\u0443\u043d\u043a\u0442 \u0441\u043e\u043f\u0440\u043e\u0432\u043e\u0434\u0438\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u043c\u0438.<\/p>\n<p>\u041d\u0430\u0447\u043d\u0435\u043c.<\/p>\n<h3>\u041e\u0433\u043b\u0430\u0432\u043b\u0435\u043d\u0438\u0435<\/h3>\n<ol>\n<li>\n<p><a href=\"#1\" rel=\"noopener noreferrer nofollow\">\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#2\" rel=\"noopener noreferrer nofollow\">\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435<\/a><\/p>\n<\/li>\n<\/ol>\n<ul>\n<li>\n<p>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/p>\n<\/li>\n<li>\n<p>\u041f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/p>\n<\/li>\n<li>\n<p>\u041e\u0431\u0437\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 Bash \u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/p>\n<\/li>\n<\/ul>\n<p>3.\u00a0<a href=\"#3\" rel=\"noopener noreferrer nofollow\">\u041a\u0430\u043a \u043d\u0430\u0447\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438<\/a><\/p>\n<ul>\n<li>\n<p>\u041a\u0430\u043a \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/p>\n<\/li>\n<li>\n<p><a href=\"#4\" rel=\"noopener noreferrer nofollow\">\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash<\/a><\/p>\n<\/li>\n<\/ul>\n<p>4.\u00a0<a href=\"#5\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u044b Bash \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/a><\/p>\n<ul>\n<li>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0438 \u0442\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 Bash<\/p>\n<\/li>\n<li>\n<p><a href=\"#6\" rel=\"noopener noreferrer nofollow\">\u0412\u0432\u043e\u0434 \u0438 \u0432\u044b\u0432\u043e\u0434 \u0432 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u0445<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#7\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash (echo, read \u0438 \u0442. \u0434.)<\/a><\/p>\n<\/li>\n<li>\n<p><a href=\"#8\" rel=\"noopener noreferrer nofollow\">\u0423\u0441\u043b\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b (\u0435\u0441\u043b\u0438\/\u0438\u043d\u0430\u0447\u0435)<\/a><\/p>\n<\/li>\n<\/ul>\n<p>5.<a href=\"#9\" rel=\"noopener noreferrer nofollow\">\u00a0\u0426\u0438\u043a\u043b\u044b \u0438 \u0432\u0435\u0442\u0432\u043b\u0435\u043d\u0438\u044f \u0432 Bash<\/a><\/p>\n<ul>\n<li>\n<p>\u0426\u0438\u043a\u043b While<\/p>\n<\/li>\n<li>\n<p>\u0426\u0438\u043a\u043b For<\/p>\n<\/li>\n<li>\n<p>\u041e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 Case<\/p>\n<\/li>\n<\/ul>\n<p>6.<a href=\"#10\" rel=\"noopener noreferrer nofollow\">\u00a0\u041f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0421ron<\/a><\/p>\n<p>7.\u00a0<a href=\"#11\" rel=\"noopener noreferrer nofollow\">\u041e\u0442\u043b\u0430\u0434\u043a\u0430 \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u043f\u043e\u043b\u0430\u0434\u043e\u043a Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/a><\/p>\n<p>8.\u00a0\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/p>\n<h3>\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f<\/h3>\n<p><a class=\"anchor\" name=\"1\" id=\"1\"><\/a><\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e\u043c\u0443 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0443, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u043c\u0435\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<p>\u0420\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f Linux \u0441 \u0434\u043e\u0441\u0442\u0443\u043f\u043e\u043c \u043a \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435.<br \/>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d Linux \u0438\u043b\u0438 \u0432\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442\u0435 \u0435\u0433\u043e \u0438\u0437\u0443\u0447\u0430\u0442\u044c, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043b\u0435\u0433\u043a\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 Linux \u0447\u0435\u0440\u0435\u0437 Replit.\u00a0<a href=\"https:\/\/replit.com\/\" rel=\"noopener noreferrer nofollow\"><u>Replit<\/u><\/a>\u00a0\u2014 \u044d\u0442\u043e \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043d\u0430\u044f IDE, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash \u0437\u0430 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u0438\u043d\u0443\u0442.<\/p>\n<p>\u0412\u044b \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u0435\u0442\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c Linux \u043f\u043e\u0432\u0435\u0440\u0445 \u0432\u0430\u0448\u0435\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b Windows, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f WSL (\u043f\u043e\u0434\u0441\u0438\u0441\u0442\u0435\u043c\u0430 Windows \u0434\u043b\u044f Linux). \u0418\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f \u043f\u043e\u00a0<a href=\"https:\/\/learn.microsoft.com\/ru-ru\/windows\/wsl\/install\" rel=\"noopener noreferrer nofollow\"><u>\u0441\u0441\u044b\u043b\u043a\u0435<\/u><\/a>.<\/p>\n<p><a class=\"anchor\" name=\"2\" id=\"2\"><\/a><\/p>\n<h3>\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435<\/h3>\n<p><strong>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/strong><\/p>\n<p>Bash-\u0441\u043a\u0440\u0438\u043f\u0442 \u2014 \u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043e\u0439 bash \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e. \u041e\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0440\u044f\u0434 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439, \u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u043a \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c\u0443 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0443, \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0430\u043f\u043a\u0438 \u0438 \u0437\u0430\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438.<\/p>\n<p>\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0432 \u044d\u0442\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438(\u0441\u043a\u0440\u0438\u043f\u0442\u044b), \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c \u043e\u0434\u043d\u0443 \u0438 \u0442\u0443 \u0436\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0448\u0430\u0433\u043e\u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0440\u0430\u0437 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0438\u0445, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439.<\/p>\n<p><strong>\u041f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/strong><\/p>\n<p>\u0421\u0446\u0435\u043d\u0430\u0440\u0438\u0438 Bash \u2014 \u044d\u0442\u043e \u043c\u043e\u0449\u043d\u044b\u0439 \u0438 \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u044b\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0433\u043e \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u043c\u0438 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c\u0438 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u0440\u0443\u0433\u0438\u0445 \u0440\u0443\u0442\u0438\u043d\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445 Unix\/Linux. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438:<\/p>\n<ul>\n<li>\n<p><strong>\u0410\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u044f<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u044e\u0449\u0438\u0435\u0441\u044f \u0437\u0430\u0434\u0430\u0447\u0438 \u0438 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u044b, \u044d\u043a\u043e\u043d\u043e\u043c\u044f \u0432\u0440\u0435\u043c\u044f \u0438 \u0441\u043d\u0438\u0436\u0430\u044f \u0440\u0438\u0441\u043a \u043e\u0448\u0438\u0431\u043e\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u0443\u0442\u044c \u043f\u0440\u0438 \u0440\u0443\u0447\u043d\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438.<\/p>\n<\/li>\n<li>\n<p><strong>\u041f\u043e\u0440\u0442\u0430\u0442\u0438\u0432\u043d\u043e\u0441\u0442\u044c<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043d\u0430 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 \u0438 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445, \u0432\u043a\u043b\u044e\u0447\u0430\u044f Unix, Linux, macOS \u0438 \u0434\u0430\u0436\u0435 Windows, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u044d\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u043e\u0432 \u0438\u043b\u0438 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043c\u0430\u0448\u0438\u043d.<\/p>\n<\/li>\n<li>\n<p><strong>\u0413\u0438\u0431\u043a\u043e\u0441\u0442\u044c<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0438 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u043b\u0435\u0433\u043a\u043e \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u044b \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u043c\u0438 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f\u043c\u0438. \u0418\u0445 \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u044f\u0437\u044b\u043a\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438\u043b\u0438 \u0443\u0442\u0438\u043b\u0438\u0442\u0430\u043c\u0438 \u0434\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0431\u043e\u043b\u0435\u0435 \u043c\u043e\u0449\u043d\u044b\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432.<\/p>\n<\/li>\n<li>\n<p><strong>\u0414\u043e\u0441\u0442\u0443\u043f\u043d\u043e\u0441\u0442\u044c<\/strong>. \u0421\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438 \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0442 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0438\u043b\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e\u0433\u043e \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f. \u0418\u0445 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043b\u044e\u0431\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430, \u0430 \u0432 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c \u0435\u0441\u0442\u044c \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438.<\/p>\n<\/li>\n<li>\n<p><strong>\u0418\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044f<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u0442\u0430\u043a\u0438\u043c\u0438 \u043a\u0430\u043a \u0431\u0430\u0437\u044b \u0434\u0430\u043d\u043d\u044b\u0445, \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440\u044b \u0438 \u043e\u0431\u043b\u0430\u0447\u043d\u044b\u0435 \u0441\u043b\u0443\u0436\u0431\u044b, \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0435\u0448\u0430\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439.<\/p>\n<\/li>\n<li>\n<p><strong>\u041e\u0442\u043b\u0430\u0434\u043a\u0430<\/strong>: \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043e\u0442\u043b\u0430\u0436\u0438\u0432\u0430\u0442\u044c, \u0438 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a \u0438\u043c\u0435\u044e\u0442 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u0438 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0430\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043c\u043e\u0433\u0430\u044e\u0442 \u0431\u044b\u0441\u0442\u0440\u043e \u0432\u044b\u044f\u0432\u043b\u044f\u0442\u044c \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0442\u044c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b.<\/p>\n<\/li>\n<\/ul>\n<p><strong>\u041e\u0431\u0437\u043e\u0440 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 Bash \u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/strong><\/p>\n<p>\u0422\u0435\u0440\u043c\u0438\u043d\u044b \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb \u0438 \u00abbash\u00bb \u0432\u0437\u0430\u0438\u043c\u043e\u0437\u0430\u043c\u0435\u043d\u044f\u0435\u043c\u044b. \u041d\u043e \u043c\u0435\u0436\u0434\u0443 \u043d\u0438\u043c\u0438 \u0435\u0441\u0442\u044c \u0442\u043e\u043d\u043a\u0430\u044f \u0440\u0430\u0437\u043d\u0438\u0446\u0430.<\/p>\n<p>\u0422\u0435\u0440\u043c\u0438\u043d \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0441\u044f \u043a \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439. Bash (Bourne Again SHell) \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0447\u0430\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0445 \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a Unix\/Linux \u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u043e\u0439 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432\u043e \u043c\u043d\u043e\u0433\u0438\u0445 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u0430\u0445 Linux.<\/p>\n<p>\u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 zsh \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u041e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432\u044b\u0432\u043e\u0434<\/figcaption><\/div>\n<\/figure>\n<p>\u0412 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u043c \u0432\u044b\u0448\u0435 \u0432\u044b\u0432\u043e\u0434\u0435 clockber::~>>\u200a\u2014\u200a\u044d\u0442\u043e \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 zsh. \u041a\u043e\u0433\u0434\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435, \u0432 Linux \u043e\u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 $, \u043a\u043e\u0433\u0434\u0430 \u043e\u0436\u0438\u0434\u0430\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u0430 \u043e\u0442 \u0438\u043c\u0435\u043d\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f root (\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0441 \u043f\u0440\u0430\u0432\u0430\u043c\u0438 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0430), \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u043d\u0430 #. \u041f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">[root@host ~]#<\/code><\/pre>\n<p>\u0425\u043e\u0442\u044f Bash\u200a\u2014\u200a\u044d\u0442\u043e \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 Korn (ksh), \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 C (csh) \u0438 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 Z (zsh). \u041a\u0430\u0436\u0434\u0430\u044f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430 \u0438\u043c\u0435\u0435\u0442 \u0441\u0432\u043e\u0439 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441 \u0438 \u043d\u0430\u0431\u043e\u0440 \u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u043d\u043e \u0432\u0441\u0435 \u043e\u043d\u0438 \u0438\u043c\u0435\u044e\u0442 \u043e\u0431\u0449\u0443\u044e \u0446\u0435\u043b\u044c\u200a\u2014\u200a\u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439.<\/p>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0441\u0432\u043e\u0439 \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b ps:<\/p>\n<pre><code class=\"bash\">ps<\/code><\/pre>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0432\u043e\u0434\u0430 \u043c\u043e\u0435\u0433\u043e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0442\u0438\u043f\u0430 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438. \u042f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 zsh<\/figcaption><\/div>\n<\/figure>\n<p>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0432 \u0442\u043e \u0432\u0440\u0435\u043c\u044f \u043a\u0430\u043a \u00ab\u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0430\u00bb\u200a\u2014\u200a\u044d\u0442\u043e \u0448\u0438\u0440\u043e\u043a\u0438\u0439 \u0442\u0435\u0440\u043c\u0438\u043d, \u043e\u0442\u043d\u043e\u0441\u044f\u0449\u0438\u0439\u0441\u044f \u043a \u043b\u044e\u0431\u043e\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0435\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438, \u00abBash\u00bb\u200a\u2014\u200a\u044d\u0442\u043e \u043e\u0441\u043e\u0431\u044b\u0439 \u0442\u0438\u043f \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445 Unix\/Linux.<\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435: \u0432 \u044d\u0442\u043e\u043c \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0435 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 \u00abbash\u00bb.<\/p>\n<p><a class=\"anchor\" name=\"3\" id=\"3\"><\/a><\/p>\n<h3>\u041a\u0430\u043a \u043d\u0430\u0447\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 Bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438<\/h3>\n<p><strong>\u041a\u0430\u043a \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b Bash \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438<\/strong><br \/>\u041a\u0430\u043a \u0443\u043f\u043e\u043c\u0438\u043d\u0430\u043b\u043e\u0441\u044c \u0440\u0430\u043d\u0435\u0435, \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">[user@host ~]$<\/code><\/pre>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0432\u0432\u0435\u0441\u0442\u0438 \u043b\u044e\u0431\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u043f\u043e\u0441\u043b\u0435 \u0437\u043d\u0430\u043a\u0430 $ \u0438 \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435.<\/p>\n<p>\u041a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u043e, \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0438\u043c\u0435\u044e\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441:<\/p>\n<pre><code>command [OPTIONS] arguments<\/code><\/pre>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 bash \u0438 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0438\u0445 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b. \u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0438\u0445 \u0432 \u0441\u0432\u043e\u0435\u043c \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435.<\/p>\n<ul>\n<li>\n<p><code>date<\/code>: \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"bash\">admin@user-new:\/$ date Sat 25 Mar 2023 14 12:04:17 PM MSK<\/code><\/pre>\n<ul>\n<li>\n<p><code>pwd<\/code>: \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u0430\u0442\u0430\u043b\u043e\u0433.<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"bash\">admin@user-new:\/usr\/lib$ pwd \/usr\/lib<\/code><\/pre>\n<ul>\n<li>\n<p><code>ls<\/code>: \u0412\u044b\u0432\u043e\u0434\u0438\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<\/li>\n<\/ul>\n<pre><code>admin@user-new:\/home$ ls clockber<\/code><\/pre>\n<ul>\n<li>\n<p><code>echo<\/code>: \u0412\u044b\u0432\u043e\u0434\u0438\u0442 \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u0441\u0442\u0440\u043e\u043a\u0443 \u0442\u0435\u043a\u0441\u0442\u0430 \u0438\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<\/li>\n<\/ul>\n<pre><code>admin@user-new:\/home$ echo \"Hello bash\" Hello bash<\/code><\/pre>\n<p>\u0412\u044b \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442\u0435 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c\u0441\u044f \u043a \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0443 \u043f\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b man.<\/p>\n<p>\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e echo \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a:<\/p>\n<figure class=\"full-width\"><\/figure>\n<p><a class=\"anchor\" name=\"4\" id=\"4\"><\/a><\/p>\n<h2>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u00a0Bash<\/h2>\n<p><strong>\u0421\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432<\/strong><\/p>\n<p>\u041f\u043e \u0441\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044e \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 bash \u0437\u0430\u043a\u0430\u043d\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u043d\u0430\u00a0.sh. \u041e\u0434\u043d\u0430\u043a\u043e \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 bash \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0431\u0435\u0437 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u044f sh.<\/p>\n<p><strong>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0428\u0435\u0431\u0430\u043d\u0433(Shebang)<\/strong><\/p>\n<p>\u0421\u043a\u0440\u0438\u043f\u0442\u044b Bash \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0442\u0441\u044f \u0441 \u0448\u0435\u0431\u0430\u043d\u0433\u0430. \u0428\u0435\u0431\u0430\u043d\u0433(Shebang)\u200a\u2014\u200a\u044d\u0442\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0430\u0446\u0438\u044f bash # \u0438 bang\u00a0! \u0437\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043f\u0443\u0442\u044c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0438 bash. \u042d\u0442\u043e \u043f\u0435\u0440\u0432\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u0441\u043a\u0440\u0438\u043f\u0442\u0430. \u0428\u0435\u0431\u0430\u043d\u0433 \u0433\u043e\u0432\u043e\u0440\u0438\u0442 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0435\u0433\u043e \u0447\u0435\u0440\u0435\u0437 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 bash. Shebang\u200a\u2014\u200a\u044d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0443 bash.<\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d \u043f\u0440\u0438\u043c\u0435\u0440 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0448\u0435\u0431\u0430\u043d\u0433.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash<\/code><\/pre>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u043f\u0443\u0442\u044c \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash (\u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u043e\u0436\u0435\u0442 \u043e\u0442\u043b\u0438\u0447\u0430\u0442\u044c\u0441\u044f \u043e\u0442 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u0432\u044b\u0448\u0435) \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b:<\/p>\n<pre><code class=\"bash\">which bash<\/code><\/pre>\n<p><strong>\u041d\u0430\u0448 \u043f\u0435\u0440\u0432\u044b\u0439 bash-\u0441\u043a\u0440\u0438\u043f\u0442<\/strong><\/p>\n<p>\u041d\u0430\u0448 \u043f\u0435\u0440\u0432\u044b\u0439 \u0441\u043a\u0440\u0438\u043f\u0442 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0432\u0432\u0435\u0441\u0442\u0438 \u043f\u0443\u0442\u044c. \u0412 \u0441\u0432\u043e\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c \u043e\u043d \u0432\u0435\u0440\u043d\u0435\u0442 \u0432\u0441\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u0444\u0430\u0439\u043b \u0441 \u0438\u043c\u0435\u043d\u0435\u043c show_all.sh \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b <code>vi<\/code>. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440 \u043f\u043e \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u044b\u0431\u043e\u0440\u0443.<\/p>\n<pre><code class=\"bash\">vi show_all.sh<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0441\u0432\u043e\u0439 \u0444\u0430\u0439\u043b \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u0435 \u0435\u0433\u043e:<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash echo \"\u0441\u0435\u0433\u043e\u0434\u043d\u044f \" `date`  echo -e \"\\n \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043f\u0443\u0442\u044c \u043a \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438:\" read path_to  echo -e \"\\n \u0432\u0430\u0448\u0430 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438:\" ls $path_to<\/code><\/pre>\n<p>\u0421\u043a\u0440\u0438\u043f\u0442 \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443 \u0438 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430.<\/p>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e. \u042f \u0441\u043d\u043e\u0432\u0430 \u043f\u0440\u0438\u0432\u043e\u0436\u0443 \u0442\u043e\u0442 \u0436\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439, \u043d\u043e \u043d\u0430 \u044d\u0442\u043e\u0442 \u0440\u0430\u0437 \u0441 \u043d\u043e\u043c\u0435\u0440\u0430\u043c\u0438 \u0441\u0442\u0440\u043e\u043a.<\/p>\n<pre><code class=\"bash\">#!\/bin\/bash echo \"\u0421\u0435\u0433\u043e\u0434\u043d\u044f \" `date`    echo -e \"\\n \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043f\u0443\u0442\u044c \u043a \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438:\" read path_to    echo -e \"\\n \u0432\u0430\u0448\u0430 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438:\" ls $path_to<\/code><\/pre>\n<ul>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #1: \u0428\u0435\u0431\u0430\u043d\u0433 (#!\/bin\/bash) \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430 \u043f\u0443\u0442\u044c \u043a \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0435 bash.<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #2: \u043a\u043e\u043c\u0430\u043d\u0434\u0430 <code>echo<\/code> \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0434\u0430\u0442\u0443 \u0438 \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u0434\u0430\u0442\u0430 \u0443\u043a\u0430\u0437\u0430\u043d\u0430 \u0432 \u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0445 \u043a\u0430\u0432\u044b\u0447\u043a\u0430\u0445.<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0440\u043e\u043a\u0430 #4: \u043c\u044b \u0445\u043e\u0442\u0438\u043c, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0432\u0432\u0435\u043b \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c.\u0421\u0442\u0440\u043e\u043a\u0430 #5: \u041a\u043e\u043c\u0430\u043d\u0434\u0430 \u0447\u0442\u0435\u043d\u0438\u044f \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0432\u0432\u043e\u0434 \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u0442 \u0435\u0433\u043e \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 path_to.<\/p>\n<\/li>\n<li>\n<p>\u0441\u0442\u0440\u043e\u043a\u0430 #8: \u041a\u043e\u043c\u0430\u043d\u0434\u0430 <code>lh<\/code> \u0431\u0435\u0440\u0435\u0442 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e \u0441 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0435 \u0444\u0430\u0439\u043b\u044b \u0438 \u043f\u0430\u043f\u043a\u0438.<\/p>\n<\/li>\n<\/ul>\n<p><strong>\u0412\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 bash-\u0441\u043a\u0440\u0438\u043f\u0442\u0430<\/strong><\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c, \u043d\u0430\u0437\u043d\u0430\u0447\u044c\u0442\u0435 \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u044b:<\/p>\n<pre><code class=\"bash\">chmod u+x show_all.sh<\/code><\/pre>\n<p>\u0413\u0434\u0435,<\/p>\n<ul>\n<li>\n<p><code>chmod<\/code> \u0438\u0437\u043c\u0435\u043d\u044f\u0435\u0442 \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0430 \u0444\u0430\u0439\u043b\u0430 \u0434\u043b\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <code>u:<\/code>.<\/p>\n<\/li>\n<li>\n<p><code>+x<\/code> \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u043c\u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c, \u044f\u0432\u043b\u044f\u044e\u0449\u0438\u0439\u0441\u044f \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0435\u043c, \u0442\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439.<\/p>\n<\/li>\n<li>\n<p><code>show_all.sh<\/code>\u200a\u2014\u200a\u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c.<\/p>\n<\/li>\n<\/ul>\n<p>\u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442 \u043b\u044e\u0431\u044b\u043c \u0438\u0437 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432:<\/p>\n<ul>\n<li>\n<p><code>sh show_all.sh<\/code><\/p>\n<\/li>\n<li>\n<p><code>bash show_all.sh<\/code><\/p>\n<\/li>\n<li>\n<p><code>.\/show_all.sh<\/code><\/p>\n<\/li>\n<\/ul>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u043e\u043d \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442?<\/p>\n<figure class=\"\"><\/figure>\n<p><a class=\"anchor\" name=\"5\" id=\"5\"><\/a><\/p>\n<h2>\u041e\u0441\u043d\u043e\u0432\u044b Bash\u00a0\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432<\/h2>\n<p><strong>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash<\/strong><\/p>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0442\u0441\u044f \u0441 # \u0432 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 bash. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043b\u044e\u0431\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430, \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0449\u0430\u044f\u0441\u044f \u0441 #, \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u043c \u0438 \u0431\u0443\u0434\u0435\u0442 \u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u043e\u043c.<\/p>\n<p>\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u043e\u0447\u0435\u043d\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u044b \u043f\u0440\u0438 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u043a\u043e\u0434\u0430, \u0438 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c \u0438\u0445, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043c\u043e\u0447\u044c \u0434\u0440\u0443\u0433\u0438\u043c \u043f\u043e\u043d\u044f\u0442\u044c \u043a\u043e\u0434.<\/p>\n<p>\u0412\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432:<\/p>\n<pre><code class=\"bash\"># This is an example comment # \u041c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0438\u0442\u044c \u043d\u0430 \u0440\u0443\u0441\u0441\u043a\u043e\u043c # These lines will be ignored by the interpreter<\/code><\/pre>\n<p><strong>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0438 \u0442\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 Bash<\/strong><\/p>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f, \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0432\u043e \u0432\u0441\u0435\u043c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438.<\/p>\n<p>\u0412 Bash \u043d\u0435\u0442 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445. \u0412 Bash \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0430\u044f \u043c\u043e\u0436\u0435\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0447\u0438\u0441\u043b\u043e\u0432\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0438\u043b\u0438 \u0441\u0442\u0440\u043e\u043a\u0438 \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432.<\/p>\n<p>\u0412 Bash \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438:<\/p>\n<ol>\n<li>\n<p>\u041d\u0430\u0437\u043d\u0430\u0447\u044c\u0442\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e:<\/p>\n<\/li>\n<\/ol>\n<pre><code class=\"bash\">country=Russia<\/code><\/pre>\n<p>2. \u041f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0432\u044b\u0432\u043e\u0434\u0430, \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u043e\u0433\u043e \u043e\u0442 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u043a\u043e\u043c\u0430\u043d\u0434. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e $ \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<pre><code class=\"bash\">same_country=$country<\/code><\/pre>\n<p>\u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439, \u0434\u043e\u0431\u0430\u0432\u044c\u0442\u0435 $ \u043a \u0438\u043c\u0435\u043d\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439.<\/p>\n<pre><code class=\"bash\">admin@user-new:\/$ country=Russia admin@user-new:\/$ echo $country Russia admin@user-new:\/$ new_country=$country admin@user-new:\/$ echo $new_country Russia<\/code><\/pre>\n<p><strong>\u0421\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445<\/strong><\/p>\n<p>\u0412 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445 Bash \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u043e\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u044f \u043e\u0431 \u0438\u043c\u0435\u043d\u0430\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445:<\/p>\n<ol>\n<li>\n<p>\u0418\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0434\u043e\u043b\u0436\u043d\u044b \u043d\u0430\u0447\u0438\u043d\u0430\u0442\u044c\u0441\u044f \u0441 \u0431\u0443\u043a\u0432\u044b \u0438\u043b\u0438 \u0441\u0438\u043c\u0432\u043e\u043b\u0430 \u043f\u043e\u0434\u0447\u0435\u0440\u043a\u0438\u0432\u0430\u043d\u0438\u044f (<em>).<\/em><\/p>\n<\/li>\n<li>\n<p><em>\u0418\u043c<\/em><\/p>\n<\/li>\n<\/ol>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-402727","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/402727","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=402727"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/402727\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=402727"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=402727"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=402727"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}