Question: How to cut words before the first “END” word in line, and not include the first character before the “END” word ( in our examples the character is “-“) 

Only with sed command

For example:

```
  echo AAA-BBB-CCC-END | sed ...
  AAA-BBB-CCC

  echo 1-END-3-4 | sed ...
  1     

  echo 1-2-END-3-4 | sed ...
  1-2

  echo PARAM1-PARAM2-END | sed ...
  PARAM1-PARAM2

  echo fileExample1-fileExample2-END | sed ...
  fileExample1-fileExample2

  echo xyz_123-END | sed ...
  xyz_123

```

Answer: 
```
sed "s/.END.*//"

```

This should do the trick.

It'll remove the first char before the END, and all chars after (and of course the END itself).
this seems to work: awkish not sedish, & literal

`awk '$0 !~ /(echo*|^$)/'`