Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2019-02-03 05:41:04
- craigbass76
- Member
- Registered: 2009-12-23
- Posts: 36
Quicker Refresh Method
Rather than have to “Update from disk” and then click OK again, is there a query I can run or something in a command like that will re-import a theme file (css, txp, etc) in one go? I’m making lots of little changes to a theme and have to keep clicking — I’d rather just alt tab to a terminal and do something quicker.
Offline
#2 2019-02-03 09:25:10
- Bloke
- Developer
- From: Leeds, UK
- Registered: 2006-01-29
- Posts: 9,993
- Website
Re: Quicker Refresh Method
Does the etc_flat plugin fit your needs for the time being until we can figure out some webhooks in core?
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#3 2019-02-03 22:22:31
- craigbass76
- Member
- Registered: 2009-12-23
- Posts: 36
Re: Quicker Refresh Method
I don’t even need a webhook, really. If it’s a PHP or a MySQL command I can run, all I’d need to do to run it again is hit the up arrow in my terminal, and Enter.
Offline
#4 2019-02-04 08:16:54
- jakob
- Admin
- From: Germany
- Registered: 2005-01-20
- Posts: 4,035
- Website
Re: Quicker Refresh Method
Did you try etc_flat? It makes development a lot easier. When activated, as long as you’re in testing or debug mode it will retrieve your page templates, forms and styles from the files rather than the database making development only a matter of saving your changes and refreshing the browser. Then, when you’re ready to switch to live, just sync the files to the database once manually.
TXP Builders – finely-crafted code, design and txp
Offline
#5 2019-02-05 03:50:48
- craigbass76
- Member
- Registered: 2009-12-23
- Posts: 36
Re: Quicker Refresh Method
Does this use more or less resources than the regular way? Wondering if I should just leave it once the site is live.
Offline
#6 2019-02-05 09:26:45
- etc
- Developer
- Registered: 2010-11-11
- Posts: 4,076
- Website
Re: Quicker Refresh Method
craigbass76 wrote #316469:
Does this use more or less resources than the regular way? Wondering if I should just leave it once the site is live.
That’s a good question, but the difference (if any) is marginal. Flat files are served only to logged-in users (mainly site developers) and only in non-live mode. Regular visitors are served from db as usual and thus do not see your changes until you deploy them. You can delete or disable the plugin when the work is done.
Offline
Pages: 1