Author Topic: StingRay's Dark Theme for CWP  (Read 652 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
StingRay's Dark Theme for CWP
« on: September 27, 2017, 07:08:08 PM »
Looking for a dark theme but can't find one, or you can't seem to override the hardcoded styles that the developers have purposely have you wait for a themeing solution? Well, I made a little script that accomplishes this, which you can run each time CWP gets updated and rewrites over your custom.css.

Head over to my Github: https://github.com/rayleesg/dark_cwp

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #1 on: September 30, 2017, 10:28:32 PM »
tried this script and got:

[root@]# ./dark_cwp
StingRay's Total Dark Theme for CWP
###################################

chmod: changing permissions of `custom.css': Operation not permitted
./dark_cwp: line 8: custom.css: Permission denied
./dark_cwp: line 9: custom.css: Permission denied
./dark_cwp: line 10: custom.css: Permission denied
./dark_cwp: line 11: custom.css: Permission denied
./dark_cwp: line 12: custom.css: Permission denied
./dark_cwp: line 13: custom.css: Permission denied
./dark_cwp: line 14: custom.css: Permission denied
./dark_cwp: line 15: custom.css: Permission denied
./dark_cwp: line 16: custom.css: Permission denied
./dark_cwp: line 17: custom.css: Permission denied
./dark_cwp: line 18: custom.css: Permission denied
./dark_cwp: line 19: custom.css: Permission denied
./dark_cwp: line 20: custom.css: Permission denied
./dark_cwp: line 21: custom.css: Permission denied
./dark_cwp: line 22: custom.css: Permission denied
./dark_cwp: line 23: custom.css: Permission denied
./dark_cwp: line 24: custom.css: Permission denied
./dark_cwp: line 25: custom.css: Permission denied
./dark_cwp: line 26: custom.css: Permission denied
./dark_cwp: line 27: custom.css: Permission denied
./dark_cwp: line 28: custom.css: Permission denied
./dark_cwp: line 29: custom.css: Permission denied
./dark_cwp: line 30: custom.css: Permission denied
./dark_cwp: line 31: custom.css: Permission denied
./dark_cwp: line 32: custom.css: Permission denied
./dark_cwp: line 33: custom.css: Permission denied
./dark_cwp: line 34: custom.css: Permission denied
./dark_cwp: line 35: custom.css: Permission denied


haven't looked to far into it yet, but here's my specs:
Distro Name: CentOS release 6.9 (Final)
Kernel Version: 2.6.32-696.10.1.el6.x86_64
CWP version: 0.9.8.272

Offline
*
Re: StingRay's Dark Theme for CWP
« Reply #2 on: October 01, 2017, 03:02:50 PM »
chattr -i custom.ss or rf -rf custom.css entirely,

then run the script

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #3 on: October 02, 2017, 02:45:13 AM »
That worked!  8)

Offline
***
Re: StingRay's Dark Theme for CWP
« Reply #4 on: October 02, 2017, 07:01:32 AM »
Nah. Didn`t work for me on CWP6. Added in the script chattr -i after cd to custom.css and chattr +i at the end of the script. I run the script, it insert everything in the custom.css - nothing. Moved custom.css to /root and run the script - nothing. Logged out, logged in - same. Am I doing something wrong?
Current uptime (FreeBSD 8.1-RELEASE-p17):
UNIX is a very simple OS, but you have to be a GENIUS to understand it ...

Offline
*
Re: StingRay's Dark Theme for CWP
« Reply #5 on: October 30, 2017, 10:33:26 AM »
Sorry for the late reply Darkness. You'd have to find custom.css in /usr/local/cwpsrv/htdocs/admin/design/css and you have to place any custom.css changes there. That's what my script does. If it worked for darkroom, should work for you too?

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #6 on: October 30, 2017, 07:05:36 PM »
CWP should switch to Bottstrap 3 or better 4 first

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #7 on: October 30, 2017, 08:57:42 PM »
@become It is already on Bootstrap3. That "Supr" theme is based on Bootstrap3.

The main problem is that CWP does not use any templating engine. Everything is hardcoded. Basically with only .css files you can't do much. And atm even .css files are locked so you can't edit them at all...unless you do some sneaky things to unlock them, but as I said, you can't do much even with unlocked .css. If you want to create custom design without html code itself you can't do much.

Offline
*
Re: StingRay's Dark Theme for CWP
« Reply #8 on: October 31, 2017, 09:45:59 AM »
For all of you that have poblem installing this script this is how I personally did it because it caused errors other way

1) Use some SFTP program and gain root access using it (WinSCP in my opinion is best)
2) Go To /usr/local/cwpsrv/htdocs/admin/design/css and copy custom.css to personal computer somewhere
3) Edit custom.css file on PC using editor from your opinion with options from script (gist with clear code - https://gist.github.com/markoidzan/e0bf9527205a04bef3df09aa1509212b)
4) DELETE original custom.css file
5) Upload edited custom.css file
6) Restart cwpsrv with service cwpsrv restart in SSH
7) enjoy in theme

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #9 on: October 31, 2017, 11:12:52 AM »
@midzan21 How did you manage to delete locked custom.css?

EDIt: Ok, I found way.
Code: [Select]
cd /usr/local/cwpsrv/htdocs/admin/design
chattr -d -suSiadAc ./css/
cd /usr/local/cwpsrv/htdocs/admin/design/css
chattr -a FILE_NAME
chattr -i FILE_NAME
« Last Edit: October 31, 2017, 11:20:30 AM by Gogo »

Offline
**
Re: StingRay's Dark Theme for CWP
« Reply #10 on: November 02, 2017, 02:14:49 AM »
one quick req... the "X" in the corner of popup windows like yum manager are almost invisible. can those be more prominent?