« first day (1384 days earlier)      last day (3568 days later) » 

4:59 AM
@Wyck was working with this yesterday, its not the quickest of queries if you look...
 
 
3 hours later…
7:59 AM
@kaiser I didn't realise grunt-githooks was part of wecodemore :)
 
 
1 hour later…
9:12 AM
Feed a troll and he will be satisfied for a day. Teach a man to troll and he will end up writing for WPMUDev.
Ouch :)
 
seems to be some hate directed @ WPMUDev a bit hey...
quite funny
 
9:44 AM
actions like redirection, filtering login url, password reset url in context of MVC. Which class should handle this? Controllers?
 
@Sisir Controllers create objects and register callbacks. They don’t execute business logic.
 
@StephenHarris we transferred it to wecodemore as the original author has no time supporting it. it's too handy to let it die by ignoring issues and PRs.
 
@kaiser Was looking at adding an option to specify a branch along with the hook (where appropriate). Still just looking through the source.
 
10:00 AM
You could just use a custom template and check the branch there.
This would be interesting to for e.g. prevent the build process if you are not on the deploy branch.
 
@kaiser I could, but then I have to have a template for each branch (potentially). And have to port that template around. From what I can tell it should be possible. Just add a conditional to the default template.
@kaiser That's it exactly why. tests on commits, and builds on the develop branch, potentially even a deploy routine on commits to master.
 
@toscho so, adding action like add_action('template_redirect', array('Core\Models\UserAccess, 'redirect')` registers by the Controllers but the actual logic runs by the Models?
 
That would be a static callback. But yes, the callback should almost always be handled by another class.
 
got it
 
10:22 AM
@StephenHarris this is what I currently got on every branch: test, build
@StephenHarris and portability of templates is one of the main reasons for templates. like task portability is the reason for the GitPHPHooksLibrary repo.
 
@kaiser Templates are defined a file, no? What I meant was an option in the Grunt task means I wouldn't have to rely on creating said files and including them in new projects.
 
what's the problem with creating such a file?
 
@kaiser chronic laziness.
 
hehe
 
10:26 AM
If you want to file a PR to include an option to target only a specific branch, please do it
 
Well, not much of a problem really: I use grunt-init templates to start most projects. But yeah, will have read through the source and try and come up with something.
 
grunt-init templates is what exactly?
 
Just a way of automating a project set-up. The end product doesn't even need to use Grunt - but often does. I have a template for a VVV site. In the command line I go to vagrant/www/, make a directory and run grunt-init vvv. It prompts me to specify stuff like site name, WP version, site url, and creates it all for me. Lastly just run vagrant up --provision.
 
10:41 AM
hey @kaiser just wanted to let you know the meetup on tuesday went really well. there actually were around 40 people, we had a nice talk, some discussion and already fixed a date for the next meetup. Also a good user/dev ratio of about 60%/40%.
 
11:11 AM
@kraftner thanks - I'm not in Austria on the 28th
(already read that date)
@StephenHarris I'm not at that point and I'm not even sure this is what I want in the end. My setup constantly moves forward and such an init template (or a Yeoman generator) doesn't allow updating things later on. It's fire and forget :)
 
11:56 AM
@kaiser adding branch option is more involved than it first seems. You can only use a hook once. So you would have to pass a branch -> task object to the hook as opposed to a string. Then you'll need to build a switch statement in the callback file to select the appropriate task(s) for the branch.
 
12:16 PM
A question about fulltime job (if any of you doing it). does 8 hours per day includes the lunchtime?
 
@Sisir Can't really tell as I freelance, but I guess this highly depends on your country and contract.
 
typically lunch break isn't work time, but might depend on country
my last full time job we had 45 min lunch, 9h mon-thu, 8h friday (15min x 4 "saved up")
 
lunch break !== work time - over here
 
@Sisir if you're expected to do 8 hours of work while at an office for 8 hours on a fulltime dayjob, then either your employers/managers are deluded, or you have an amazing ecstatic job with work that would make even the most hedonistic billionaire jealous and the most obsessive OCD seem tame
people will take breaks wether they like it or not, 60-70% of the time spent doing actual work is a reasonable figure
 
+1, 8h of work isn't really happening anyway :)
 
12:26 PM
the best they can do is make people get lost in thought on unofficial breaks
 
got it..
 
Well I guess the actual question boils down to the time between arriving at and leaving the office. How much you really work in between is a different thing ;)
 
yeah, work time in office is essentially "time manager can see you"
 
the rules varies I guess.. here in bangladesh lunchtime generally included with the work time. but 8hrs per day for work is pretty much standard everywhere
 
@Sisir are most of your clients local or mostly foreign?
 
12:30 PM
I had a job with like super-strict, timestamped, 5 min late and boss is reprimanding you work time... some people arrived strictly on time, then grabbed coffee and wandered off to chat around for hour or two
 
I do not work locally. I am employed fulltime remotely to an US client. I clearly remember he said 40hrs/week with lunchtime included. We didn't have any paperwork. Today, he said taking lunch break was unethical for me. :/
 
once a guy got caught up in work discussion with someone from other department after entering building and got chewed for putting working ahead of showing up at his desk
@Sisir many of americans are crazy workaholics, after working for them for a while I am never putting up with their terms again
to be fair they run themselves into ground too, but no reason to nosedive with them
 
@Sisir We all hate paperwork, but to be honest that is the reason it exists (and can help you if done right)
 
realistically paperwork doesn't mean shit between countries on small/medium business level. people will try to get away with as much as they can regardless
 
yea.. but paperwork pretty much worthless when you working remotely. You can't sue someone offshore ;)
 
12:36 PM
if you have leverage they won't dare screw with you, if you don't they will screw with you without paying second thought to any agreements
obviously talking nightmare worst case scenario :)
I feel the whole startup fad is actually pushing some people over there to more sane business and life practices :)
 
Okay good point about lack of enforceability when working remote. It then probably boils down to be sure to get your money in short intervals and then be ethical and do what you feel is right. But of course I'm not a lawyer...
 
or write incredibly bad and complicated code to make yourself essential
 
why bother doing poor work? :)
 
@Wyck i do it always without any extra effort :)
 
Complicated and undocumented should be enough. Lock-In FTW! ;)
 
12:45 PM
as long as it works and no one else understands it
 
if you are doing shit job you are just having orders of magnitude more of competition
 
with wordpress it not an issue, but I know lots of people who get themselves into situations where they become very costly and hard to replace
in other words leverage
 
i want to leave.. never going to signup with any more fulltime job unless I know all details
it's hard to get a fulltime job though. But with freelancing there is more time to learn
 
ya the good ones let you have a day to do what you want, but those companies are rare
 
1:16 PM
@kaiser Continuing on our Vagrant talk recently I now also came to the conclusion that I either arrange myself with the way VVV works or create my own. Nothing really fits my needs/expectations.
Jul 22 at 19:13, by kaiser
but yes, @s1lv3r I started working on my own VM setup, but haven't got time to finish it. I just waste all those precious minutes discussing what I could do with you guys :D
Is this still valid? If yes should we compare our approaches just in case we want the same before starting building stuff twice...
 
Someone should a packer.io wordpress package that includes wp-cli and DO
 
or docker
 
packer sounds like a provisioner
why not puppet or ansible
 
anu
docker? to use docker properly, you'd need multiple docker containers
 
see how this stuff is confusing like hell and evolving too fast at the moment (or is it just me?)
 
1:28 PM
ya packer is similar to puppet, works with puppet as well I think it's probably less complex (haven't used it)
basically packer is at a higher level and a level below you would use puppet or docker or whatever
 
just skimming through packer.io it seems as it is meant to build vm images. how this is actually done is up to you. e.g. using puppet or alike
 
yes exactly, and it works with the amazon and do api
 
yeah! one more layer for the stack!
 
I wish I had the time to build something with it because I could really use it
 
I am curious how many sites do you people actually run to bother with this stuff? thousands? hundreds? dozens? three? :)
 
1:32 PM
:)
 
I don't bother with any of this stuff, where I work we make about 40 sites per year and maintain them for 3-5 years typically
 
not enough to be honest.
 
I need all this stuff about as much as I need WordPress tattoo
 
What?? You do not have one?
 
I would like to be able to replicate our staging sites using packer and do, and automate find+ replace and several wp-cli commands
 
1:35 PM
omg
 
as in I just press a button and I have a site I can debug even if its for 5 minutes
 
anu
@rarst it's a bit like constructing a deployment mechanism - sure you can live without it, but why not automate this stuff? Sure, it's pointless spending weeks to save days of effort, but the time I've spent on capistrano deployment and building a vagrant instance is already paying off for me
 
at the end of the day I really like buttons, I want one button that does everything
 
@anu you are dodging "but how many sites?" question well :)
 
packer.io sounds like vagrant + puppet + VVV + it's like docker confusion
@kraftner the benefit of that tattoo is in a few weeks it's hidden under an arm of hair
 
1:38 PM
I was just shocked that google image search actually came up with a couple of WP tattoos. I hope most of them are fake...
 
@kraftner they aren't
 
@TomJNowell Yeah I think that really goes to far.
 
I wouldn't mind a very simple and small blue transferrable tattoo, the sort that you get off a sticker and wash off a day or two later
 
anu
@Rarst i don't necessarily think the # of servers is really that important, it's more about starting to treat servers as disposable/ephemeral and being able to rebuild them easily from scratch. Or about having a very portable development infrastructure.
 
I need to finish up process to copying new UniformServer to my notebook... anyone knows if Apache does drive-relative paths? :)
 
1:42 PM
unlikely, it was built with *nix in mind
and there are no driver letters in *nix
 
Let's not start that discussion again. There are valid reasons (like sandboxing sites) even with a small amount of sites.
 
how does it distinguish multiple physical drives?
@kraftner starting? you were chatting for like five pages about it before I said anything yawn :)
 
@Rarst drives are represented in the file system as objects, and they get mounted into folders, which folder that is can be chosen, but convention puts them in /mnt/ normally
the same way sockets can be piped into as if they were files, even though they dont exist as a file on any physical hardware
 
@Rarst I meant not start the discussion whether it makes sense again and instead talk about how for those who care.
 
anu
@kraftner If there are questions / discussions about why this is a good idea, that's perfectly fine.
 
1:50 PM
Okay okay... It is just because we already had this from here on: chat.stackexchange.com/transcript/6?m=16721758#16721758
 
2:00 PM
wordpress runs on practically everything
 
wordpress is backwards compatible with commodore64
 
vagrant that !
 
muhaha
 
 
1 hour later…
3:19 PM
@Wyck vagrant VICE - not really a problem ;)
 
3:39 PM
wow it exsists lol
 
4:14 PM
0
Q: Should we protect Popular Answered Off-Topic Questions?

Howdy_McGeeLately I've been going through some of the popular plugin tags and marking questions as off-topic to clean up. I've run across a few that are technically Off-Topic but may also be helpful to future viewers / searchers. BuddyPress Example of a Relatively Popular answered question Contact Form 7...

 
 
2 hours later…
6:28 PM
did not know this function existed post_type_archive_title();
 
is this from wp-includes/seo.php?
 
ha yep
 
0
Q: need a plugin that can do it all

user57455I want a map plug-in for WordPress, that will allow me to upload multiple locations from a file. And the most important thing is I want users that are logged in to be able to add locations to the map as well. Let me know if there's any map plug-ins that fit this criteria? Thank you for your hel...

Title of the day.
 
Just want your short experienced observation:
Separated the loop contents into only two parts:
- Archive Post Content (for all types of archives and post formats)
- Page Content (for Single and Page)

In Archive Post Content I loaded some different classes to style 'em differently checking the post formats using `has_post_format()`.

So there's a series there in this template part like:

$ps_gallery = has_post_format( 'gallery' );
if( $ps_gallery ) {
$ps_class = 'fa-th';
$ps_title = __('Post Format Gallery', 'textdomain');
 
6:50 PM
@MayeenulIslam it could get messy, you can instead use get_template_part( '.someplace/', get_post_format() );
 
@MayeenulIslam or make use of post_class/body_class and according hooks to add the classes you want, this way you can put all the conditional logic into the functions.php or a plugin instead of having it in the template
 

« first day (1384 days earlier)      last day (3568 days later) »