8 – Patch drupal.org project (core/module/theme) with issue fork

The new fork based merge request (MR) approach is pretty neat to get the patches created/reviewed/merged. However, if you are using the patch via cweagans/composer-patches, we have a few options.

Option 1: we can use the MR to add the patch like this:

"drupal/message": {
  "3186091": "https://git.drupalcode.org/project/message/-/merge_requests/1.patch"

but it means any new change pushed to the fork/branch, would get automatically added. As the patch file gets pulled on composer install.

Option 2:
We could use the fork’s branch and commit hash to keep the patch static, but once the MR merged, the fork might get deleted and breaks the build.

Option 3: Obviously we can generate the patch from the MR and upload to the issue comment, but it seems a duplicate effort and hard to keep up with an active core issue (right now, we just need to update the patch file in composer.json or composer.patches.json)

Is there a way to have the current patch file behavior in the new fork based issue queue?

UPDATE: Both option 1 and (probably) option 3 are documented on drupal.org

lighting – UNITY : how to pause baking and quit project?

How to pause the lighting bake and quit the project ? so when i re-open the scene it will continue baking without have to start the bake from beginning ?

I need to take a break to do other job on my computer, because after i turn on ‘auto generate’ , the baking takes very very long. I want to quit unity and continue later.

Right now if i reopen the project , it will bake from start again.


sharepoint online – MS Project file opening in read only mode

We had an MS Project file on SharePoint Online that is synced to the task list. Before I joined the company something happened (I realize it’s not helpful but nobody understands what happened) which caused the Project file to open always in read only mode. We cannot resave it or do anything else because an error keeps popping up that the file is read only.

I tried deleting all of the tasks from the SharePoint task list and to restore the Project file to a previous version before the problems started occuring, and try and resync it but it is still throwing the read only error when trying to sync.

security – For a very long lived PHP web application project, is custom (self made) framework better than (open source) popular frameworks?

There is a lot to unpack here. Let’s start with…

1. Security through obscurity

Obscurity in and of itself does not provide additional security, unless it is so utterly complete and total, that it barely balances being usable.

Are your company records secret?

Are you sure an attacker can’t find out who used to work for your devteam?

Are you sure none of ex- or current employees have any copies of the source code on their home machines?

Are you sure that they maintain secrecy and will not spill the beans willingly upon social engineering attempt?

Is your server running an OS that has no vulnerabilities?

Are you absolutely sure an attacker can’t get access directly to the server physically?

Is your team really THAT good and all the points of contact (which are exposed and therefore not obscured at all) in your framework are secure?

If you can’t answer a strong “YES” to every one of those questions (and many others), than obscurity is not going to help much.

Which brings us to…

2. More open means more secure

It is just a simple numbers game. There is a set percentage of security specialists amongst the population of developers in the world. If more people have access to your code—higher number of professionals will check it out and spot the problem.

This has been the working solution for pretty much every collaborative project in the past couple hundred years. That is how Wikipedia operates. And it is how most modern frameworks operate. They are open sourced in part due to security concerns. It allows them to prove that they are not hiding anything, and in turn, security professionals from all around the world have an opportunity to contribute their experience and skills to the creation of these frameworks.

The dedicated security solutions implemented in open source frameworks will beat you in terms of security. That is, unless you are absolutely sure that your team is able to achieve a world-class security in your custom-tailored closed-source project. Which brings me to…

3. Longevity of code

You have to rememember, that your framework is not floating through the void of space. Your code interacts with a lot of other systems.

You say that you use PHP5. It is now firmly in its “end of life” stage and will never be updated again. Are you comfortable using a system that has a bunch of well-known and widely publicized vulnerabilities? No matter how good your code is, and how strongly you obscure your system, those are not going anywhere.

When you say that PHP5 will still run on servers, do you imply that it will just work indefinitily? Because it most surely won’t. As the years go by, support for it will be dropped by major webservers, because there is no reason to drag all of this old, vulnerable, and barely used code along.

So unless you are going to keep your entire architecture the same for the next 50 years, your application is going to stop working as expected at some point. And if you do, then expect to have a lot more vulnerabilities to worry about.

4. Nothing lasts forever

Here is a list of things that did not exist 30 years ago: https, http cookies, JavaScript, PHP.

It is difficult to tell what the web will be like in 5–10, let alone 50 years. Requirements will change. Your application will have to adapt. If your team can pull off writing an web application that will live for so long, using a closed-source framework, based on technologies that are already dying—hats off to you.

linux – How can I successfully migrate an Android Studio project across OSes and Versions of Android Studio?

I need some assistance migrating a project from one version of Android Studio to another. This was generally not a problem when I updated the program automatically. The projects carried across fine and updated themselves.

But when porting the project say from Arch Linux Android studio 2 to Kali Linux Android Studio 3, I find that there are a number of errors, ranging from;

  • The git/cvs repo not being recognized as a repository in the new system. Although the old branches are visible as options, just cannot be selected.
  • Gradle build errors because the wrappers properties file is empty.

I will leave it there for now. Anyone who has attempted it and found the process easy please comment, anyone who has done it and encountered problems please comment, and anyone who has solved it or might have an idea please provide your feedback/solution.

No edit icon for file of forked GitHub project on Chrome Browser

I am trying to add some details to the forked project and so i like to pull it to the main project i am searching the edit icon on ht page of GitHub project and i have seen this instruction but i can not found the edit icon via that page.

Now can not see any edit icon via the GitHub page, the page is like this:

enter image description here

So i want to know it is possible by GitHub page via chrome browser to do it or it must be done by command like git clone <Project-url> and others git commands?


8 – How can I use Drush in a project installed with Composer?

Just an addition for windows users.

lesley n. answer above works just fine for Windows users as well.

Just edit C:Usersyour_username.bash_profile and add one line:

alias drush='vendor/bin/drush'

Restart your Git Bash, go to your drupal site home folder and try:

drush version

It should work

I was able to make composer-installed Drupal Console to work with only “drupal” command also with one line addition to C:Usersyour_username.bash_profile as well:

alias drupal='vendor/bin/drupal'

Restart your Git Bash, go to your drupal site home folder and try:

drupal --version

This should work as well.

These two solutions are much easier for me than installing Drush Launcher and Console Launcher on my Windows platform.

Can anyone review my WebChainEVO project?


Admin: If i can’t share my project here, please remove this thread. Thanks

WebChainEVO is a recent site that i created to share my favorite content and my tools…
Visit: http://www.webchainevo.oxn.pl


How to revert to an old project version of project in xcode?

If i use a local GIT repository, can i use it to revert to an old version of the project?

For example, I have 10 commits, I want to go back to the 5th version. How to do it?

gnu make – Using Gnu autotools library in CMake project

I want to ask you a little question. In a project based on gnu-autotools I can use use my library(libtest based on gnu autotools) with a construction "pkg-config --cflags libtest" for include directory.

But the project based on Cmake I must use *.cmake config files (Or construction include_directories ("/usr/local/include/libtest") but this is ugly in my opinion).

How can I write and add this *.cmake files in my library? Do you know any library where I can see example? Or where I can read about this?

Regards, max