0

Hey guys i'm learning how to code shell scripts and tried to do a simple html page. My script looks like this:

#!/bin/bash

# sysinfo_page - A script to produce an html file

cat <<- _EOF_
<html>
    <head>
        <title>
        The title of your page
        </title>
    </head>

    <body>
        Your page content goes here.
    </body>
</html>
_EOF_

And it's saved in my $HOME/bin, but doesn't quite work. Path is okay because i have other simple script working from there (Hello World). This one creates the html file but empty, and i don't know why. When i use command:

sysinfo_page > sysinfo_page.html

First it tells me i have no permission so i have to use sudo for this, and then tells me

sudo: sysinfo_page: command not found

But the sysinfo_page.html is created empty anyway.

Animu
  • 11

0 Answers0