Let me have a second try.
The items artifactId
and version
cannot be influenced by plugin generated properties. To influence them, the property must be given on the command line (or maybe in the POM directly).
So we are left with the classifier.
You need to build all artifacts with classifiers in the same build. So you need to change the build in a way that it builds for the different OS in one go. I don't know whether that is possible (depending on whether you can build e.g. for Windows on Linux) but it seems to be the only "Maven way" solution for you problem.
Of course, you could still try tricks like deleting the POM after you have deployed it, but if possible this should be avoided.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…